실행 실패 (제출 코드 컴파일 에러)
{"stderr": "Main.cpp: In function \u2018int main()\u2019:\nMain.cpp:35:15: error: no match for \u2018operator+=\u2019 (operand types are \u2018std::string\u2019 {aka \u2018std::__cxx11::basic_string<char>\u2019} and \u2018<unresolved overloaded function type>\u2019)\n 35 | str += q.front;\n | ~~~~^~~~~~~~~~\nIn file included from /usr/include/c++/11/string:55,\n from /usr/include/c++/11/bits/locale_classes.h:40,\n from /usr/include/c++/11/bits/ios_base.h:41,\n from /usr/include/c++/11/ios:42,\n from /usr/include/c++/11/ostream:38,\n from /usr/include/c++/11/iostream:39,\n from Main.cpp:1:\n/usr/include/c++/11/bits/basic_string.h:1203:9: note: candidate: \u2018template<class _Tp> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_If_sv<_Tp, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator+=(const _Tp&) [with _Tp = _Tp; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]\u2019\n 1203 | operator+=(const _Tp& __svt)\n | ^~~~~~~~\n/usr/include/c++/11/bits/basic_string.h:1203:9: note: template argument deduction/substitution failed:\nMain.cpp:35:20: note: couldn\u2019t deduce template parameter \u2018_Tp\u2019\n 35 | str += q.front;\n | ^~~~~\nIn file included from /usr/include/c++/11/string:55,\n from /usr/include/c++/11/bits/locale_classes.h:40,\n from /usr/include/c++/11/bits/ios_base.h:41,\n from /usr/include/c++/11/ios:42,\n from /usr/include/c++/11/ostream:38,\n from /usr/include/c++/11/iostream:39,\n from Main.cpp:1:\n/usr/include/c++/11/bits/basic_string.h:1160:7: note: candidate: \u2018std::__cxx11::basic_string<_CharT, _Traits, _Alloc>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator+=(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]\u2019\n 1160 | operator+=(const basic_string& __str)\n | ^~~~~~~~\n/usr/include/c++/11/bits/basic_string.h:1160:38: note: no known conversion for argument 1 from \u2018<unresolved overloaded function type>\u2019 to \u2018const std::__cxx11::basic_string<char>&\u2019\n 1160 | operator+=(const basic_string& __str)\n | ~~~~~~~~~~~~~~~~~~~~^~~~~\n/usr/include/c++/11/bits/basic_string.h:1169:7: note: candidate: \u2018std::__cxx11::basic_string<_CharT, _Traits, _Alloc>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator+=(const _CharT*) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]\u2019\n 1169 | operator+=(const _CharT* __s)\n | ^~~~~~~~\n/usr/include/c++/11/bits/basic_string.h:1169:32: note: no known conversion for argument 1 from \u2018<unresolved overloaded function type>\u2019 to \u2018const char*\u2019\n 1169 | operator+=(const _CharT* __s)\n | ~~~~~~~~~~~~~~^~~\n/usr/include/c++/11/bits/basic_string.h:1178:7: note: candidate: \u2018std::__cxx11::basic_string<_CharT, _Traits, _Alloc>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator+=(_CharT) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]\u2019\n 1178 | operator+=(_CharT __c)\n | ^~~~~~~~\n/usr/include/c++/11/bits/basic_string.h:1178:25: note: no known conversion for argument 1 from \u2018<unresolved overloaded function type>\u2019 to \u2018char\u2019\n 1178 | operator+=(_CharT __c)\n | ~~~~~~~^~~\n/usr/include/c++/11/bits/basic_string.h:1191:7: note: candidate: \u2018std::__cxx11::basic_string<_CharT, _Traits, _Alloc>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator+=(std::initializer_list<_Tp>) [with _CharT =(...truncated, total 4463 characters)
정답 개수:
-
틀린 개수:
-
실행 실패 개수:
-
반례를 발견하지 못했습니다.