실행 실패 (제출 코드 컴파일 에러)
Main.cpp: In function ‘int main()’: Main.cpp:15:21: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 15 | for (int j = 0; j < tosrs.length(); j++) { | ~~^~~~~~~~~~~~~~~~ Main.cpp:16:16: error: no matching function for call to ‘stoi(__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type&)’ 16 | zetoni[stoi(tosrs[j])] += 1; | ~~~~^~~~~~~~~~ In file included from /usr/include/c++/11/string:55, from /usr/include/c++/11/bits/locale_classes.h:40, from /usr/include/c++/11/bits/ios_base.h:41, from /usr/include/c++/11/ios:42, from /usr/include/c++/11/ostream:38, from /usr/include/c++/11/iostream:39, from Main.cpp:1: /usr/include/c++/11/bits/basic_string.h:6619:3: note: candidate: ‘int std::__cxx11::stoi(const string&, std::size_t*, int)’ 6619 | stoi(const string& __str, size_t* __idx = 0, int __base = 10) | ^~~~ /usr/include/c++/11/bits/basic_string.h:6619:22: note: no known conversion for argument 1 from ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type’ {aka ‘char’} to ‘const string&’ {aka ‘const std::__cxx11::basic_string<char>&’} 6619 | stoi(const string& __str, size_t* __idx = 0, int __base = 10) | ~~~~~~~~~~~~~~^~~~~ /usr/include/c++/11/bits/basic_string.h:6750:3: note: candidate: ‘int std::__cxx11::stoi(const wstring&, std::size_t*, int)’ 6750 | stoi(const wstring& __str, size_t* __idx = 0, int __base = 10) | ^~~~ /usr/include/c++/11/bits/basic_string.h:6750:23: note: no known conversion for argument 1 from ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type’ {aka ‘char’} to ‘const wstring&’ {aka ‘const std::__cxx11::basic_string<wchar_t>&’} 6750 | stoi(const wstring& __str, size_t* __idx = 0, int __base = 10) | ~~~~~~~~~~~~~~~^~~~~
정답 개수:
-
틀린 개수:
-
실행 실패 개수:
-
비공개 코드입니다. 코드 작성자만 볼 수 있습니다.
반례를 발견하지 못했습니다.