submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
language
stringclasses
3 values
code
stringlengths
1
522k
compiler_output
stringlengths
43
10.2k
s041696055
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; getline(cin, S) ; cout << "A" + S[8] +"C" << endl; }
a.cc: In function 'int main()': a.cc:8:20: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 8 | cout << "A" + S[8] +"C" << endl; | ^~~~ | | | const char [2]
s433561977
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string at; cin >> at; cout << A << at.at(7) << C << endl; }
a.cc: In function 'int main()': a.cc:7:11: error: 'A' was not declared in this scope 7 | cout << A << at.at(7) << C << endl; | ^ a.cc:7:28: error: 'C' was not declared in this scope 7 | cout << A << at.at(7) << C << endl; | ^
s910857657
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string A, X; cin >> A >> X; char x = X.at(0) cout << "A" + x + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:3: error: expected ',' or ';' before 'cout' 8 | cout << "A" + x + "C" << endl; | ^~~~
s269598729
p03860
C++
#include "pch.h" #include <iostream> #include <string> #include <vector> using namespace std; int main(void) { string s1, s2, s3; cin >> s1 >> s2 >> s3; cout << 'A' << s2.at(0) << 'C' << endl; }
a.cc:2:10: fatal error: pch.h: No such file or directory 2 | #include "pch.h" | ^~~~~~~ compilation terminated.
s697599308
p03860
C++
#include <iostream> #include <string> using namespace std; int main() { string words[3]; for(int i = 0; i < 3; ++i) { cin >> words[i]; } char initisls[3]; for(int i = 0; i < 3; ++i) { initisls[i] = words[i].front(); } cout << word << endl; }
a.cc: In function 'int main()': a.cc:17:17: error: 'word' was not declared in this scope; did you mean 'words'? 17 | cout << word << endl; | ^~~~ | words
s679468031
p03860
C++
#include <iostream> #include <string> using namespace std; int main() { string words[3]; for(int i = 0; i < 3; ++i) { cin >> words[i]; } char initisls[3]; for(int i = 0; i < 3; ++i) { initisls[i] = words[i].substr(1); } cout << word << endl; }
a.cc: In function 'int main()': a.cc:15:36: error: cannot convert 'std::__cxx11::basic_string<char>' to 'char' in assignment 15 | initisls[i] = words[i].substr(1); | ~~~~~~~~~~~~~~~^~~ | | | std::__cxx11::basic_string<char> a.cc:17:17: error: 'word' was not declared in this scope; did you mean 'words'? 17 | cout << word << endl; | ^~~~ | words
s575612293
p03860
C++
#include <iostream> using namespace std; int main() { char word[3]; for(int i = 0; i < 3; ++i) { cin << word[i]; } cout << word << endl; }
a.cc: In function 'int main()': a.cc:9:21: error: no match for 'operator<<' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'char') 9 | cin << word[i]; | ~~~ ^~ ~~~~~~~ | | | | | char | std::istream {aka std::basic_istream<char>} a.cc:9:21: note: candidate: 'operator<<(int, int)' (built-in) 9 | cin << word[i]; | ~~~~^~~~~~~~~~ a.cc:9:21: note: no known conversion for argument 1 from 'std::istream' {aka 'std::basic_istream<char>'} to 'int' In file included from /usr/include/c++/14/bits/basic_string.h:47, from /usr/include/c++/14/string:54, from /usr/include/c++/14/bits/locale_classes.h:40, from /usr/include/c++/14/bits/ios_base.h:41, from /usr/include/c++/14/ios:44, from /usr/include/c++/14/ostream:40, from /usr/include/c++/14/iostream:41, from a.cc:1: /usr/include/c++/14/string_view:763:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, basic_string_view<_CharT, _Traits>)' 763 | operator<<(basic_ostream<_CharT, _Traits>& __os, | ^~~~~~~~ /usr/include/c++/14/string_view:763:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/bits/basic_string.h:4077:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const __cxx11::basic_string<_CharT, _Traits, _Allocator>&)' 4077 | operator<<(basic_ostream<_CharT, _Traits>& __os, | ^~~~~~~~ /usr/include/c++/14/bits/basic_string.h:4077:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ In file included from /usr/include/c++/14/bits/memory_resource.h:38, from /usr/include/c++/14/string:68: /usr/include/c++/14/cstddef:125:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator<<(byte, _IntegerType)' 125 | operator<<(byte __b, _IntegerType __shift) noexcept | ^~~~~~~~ /usr/include/c++/14/cstddef:125:5: note: template argument deduction/substitution failed: a.cc:9:17: note: cannot convert 'std::cin' (type 'std::istream' {aka 'std::basic_istream<char>'}) to type 'std::byte' 9 | cin << word[i]; | ^~~ In file included from /usr/include/c++/14/bits/ios_base.h:46: /usr/include/c++/14/system_error:339:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const error_code&)' 339 | operator<<(basic_ostream<_CharT, _Traits>& __os, const error_code& __e) | ^~~~~~~~ /usr/include/c++/14/system_error:339:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:563:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, _CharT)' 563 | operator<<(basic_ostream<_CharT, _Traits>& __out, _CharT __c) | ^~~~~~~~ /usr/include/c++/14/ostream:563:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:573:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, char)' 573 | operator<<(basic_ostream<_CharT, _Traits>& __out, char __c) | ^~~~~~~~ /usr/include/c++/14/ostream:573:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:579:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, char)' 579 | operator<<(basic_ostream<char, _Traits>& __out, char __c) | ^~~~~~~~ /usr/include/c++/14/ostream:579:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:590:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, signed char)' 590 | operator<<(basic_ostream<char, _Traits>& __out, signed char __c) | ^~~~~~~~ /usr/include/c++/14/ostream:590:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:595:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, unsigned char)' 595 | operator<<(basic_ostream<char, _Traits>& __out, unsigned char __c) | ^~~~~~~~ /usr/include/c++/14/ostream:595:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:654:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const _CharT*)' 654 | operator<<(basic_ostream<_CharT, _Traits>& __out, const _CharT* __s) | ^~~~~~~~ /usr/include/c++/14/ostream:654:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ In file included from /usr/include/c++/14/ostream:1022: /usr/include/c++/14/bits/ostream.tcc:307:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const char*)' 307 | operator<<(basic_ostream<_CharT, _Traits>& __out, const char* __s) | ^~~~~~~~ /usr/include/c++/14/bits/ostream.tcc:307:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:671:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, const char*)' 671 | operator<<(basic_ostream<char, _Traits>& __out, const char* __s) | ^~~~~~~~ /usr/include/c++/14/ostream:671:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:684:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, const signed char*)' 684 | operator<<(basic_ostream<char, _Traits>& __out, const signed char* __s) | ^~~~~~~~ /usr/include/c++/14/ostream:684:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:689:5: note: candidate: 'template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(basic_ostream<char, _Traits>&, const unsigned char*)' 689 | operator<<(basic_ostream<char, _Traits>& __out, const unsigned char* __s) | ^~~~~~~~ /usr/include/c++/14/ostream:689:5: note: template argument deduction/substitution failed: a.cc:9:30: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>' 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:810:5: note: candidate: 'template<class _Ostream, class _Tp> _Ostream&& std::operator<<(_Ostream&&, const _Tp&)' 810 | operator<<(_Ostream&& __os, const _Tp& __x) | ^~~~~~~~ /usr/include/c++/14/ostream:810:5: note: template argument deduction/substitution failed: /usr/include/c++/14/ostream: In substitution of 'template<class _Ostream, class _Tp> _Ostream&& std::operator<<(_Ostream&&, const _Tp&) [with _Ostream = std::basic_istream<char>&; _Tp = char]': a.cc:9:18: required from here 9 | cin << word[i]; | ^ /usr/include/c++/14/ostream:810:5: error: no type named 'type' in 'struct std::enable_if<false, void>' 810 | operator<<(_Ostream&& __os, const _Tp& __x)
s527218346
p03860
C++
#include <iostream> namespace std; int main() { char word[3]; for(int i = 0; i < 3; ++i) { cin << word[i]; } cout << word << endl; }
a.cc:2:14: error: expected '{' before ';' token 2 | namespace std; | ^ a.cc: In function 'int main()': a.cc:9:17: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 9 | cin << word[i]; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; ///< Linked to standard input | ^~~ a.cc:11:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'? 11 | cout << word << endl; | ^~~~ | std::cout /usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here 63 | extern ostream cout; ///< Linked to standard output | ^~~~ a.cc:11:19: error: 'endl' was not declared in this scope; did you mean 'std::endl'? 11 | cout << word << endl; | ^~~~ | std::endl In file included from /usr/include/c++/14/iostream:41: /usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here 744 | endl(basic_ostream<_CharT, _Traits>& __os) | ^~~~
s136329610
p03860
C++
#include <iostream> int main() { char word[3]; for(int i = 0; i < 3; ++i) { cin << word[i]; } cout << word << endl; }
a.cc: In function 'int main()': a.cc:8:17: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 8 | cin << word[i]; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; ///< Linked to standard input | ^~~ a.cc:10:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'? 10 | cout << word << endl; | ^~~~ | std::cout /usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here 63 | extern ostream cout; ///< Linked to standard output | ^~~~ a.cc:10:19: error: 'endl' was not declared in this scope; did you mean 'std::endl'? 10 | cout << word << endl; | ^~~~ | std::endl In file included from /usr/include/c++/14/iostream:41: /usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here 744 | endl(basic_ostream<_CharT, _Traits>& __os) | ^~~~
s679133729
p03860
C++
#include<bits/stdc++.h> using namespace std; int main(){ string a, s, c; cin >> a >> s >> c; cout << a.at(0) << s.at(0) << c.at(0) << endls; }
a.cc: In function 'int main()': a.cc:7:44: error: 'endls' was not declared in this scope 7 | cout << a.at(0) << s.at(0) << c.at(0) << endls; | ^~~~~
s210451380
p03860
C++
#include<bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (int)(n); i++) using namespace std; using ll = long long; using p = pair<int, int>; typedef vector<int> vi; int main() { string a, b, c; cin >> a >> b >> c; string ans = a[0]+b[0]+c[0]; cout << ans << endl; return 0; }
a.cc: In function 'int main()': a.cc:11:25: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested 11 | string ans = a[0]+b[0]+c[0];
s488929768
p03860
C++
#include<iostream> using namespace std; int main(){ string first,second.third; cin>>first>>second>>third; cout<<first[0]<<second[0]<<third[0]; }
a.cc: In function 'int main()': a.cc:4:22: error: expected initializer before '.' token 4 | string first,second.third; | ^ a.cc:5:15: error: 'second' was not declared in this scope 5 | cin>>first>>second>>third; | ^~~~~~ a.cc:5:23: error: 'third' was not declared in this scope 5 | cin>>first>>second>>third; | ^~~~~
s335494061
p03860
C
#include<bits/stdc++.h> using namespace std; int main() { string a,b,c; cin>>a>>b>>c; cout<<a[0]<<b[0]<<c[0]<<endl; }
main.c:1:9: fatal error: bits/stdc++.h: No such file or directory 1 | #include<bits/stdc++.h> | ^~~~~~~~~~~~~~~ compilation terminated.
s269897394
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> AtCoder s Contest; cout << "A" << s.at(7) << "C" << endl; }
a.cc: In function 'int main()': a.cc:6:10: error: 'AtCoder' was not declared in this scope 6 | cin >> AtCoder s Contest; | ^~~~~~~
s422727061
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; cout << "A" << s.at(0) << "C" }
a.cc: In function 'int main()': a.cc:8:32: error: expected ';' before '}' token 8 | cout << "A" << s.at(0) << "C" | ^ | ; 9 | 10 | } | ~
s455642122
p03860
C++
#include <iostream> #include <vector> #include <range/v3/all.hpp> int main() { using namespace ranges; auto result = istream_view<std::string>(std::cin> | views::transform([](const auto &word){ return word[0]; }) | to<std::string>(); std::cout << result << std::endl; }
a.cc:3:10: fatal error: range/v3/all.hpp: No such file or directory 3 | #include <range/v3/all.hpp> | ^~~~~~~~~~~~~~~~~~ compilation terminated.
s403401059
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string a , x , c; cin >> a >> x >> c ; cout >> a.at(0) + x.at(0) + c.at(0) << endl; }
a.cc: In function 'int main()': a.cc:11:14: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ~~~~ ^~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:11:14: note: candidate: 'operator>>(int, int)' (built-in) 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ a.cc:11:14: note: no known conversion for argument 1 from 'std::ostream' {aka 'std::basic_ostream<char>'} to 'int' In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41, from a.cc:1: /usr/include/c++/14/cstddef:131:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(byte, _IntegerType)' 131 | operator>>(byte __b, _IntegerType __shift) noexcept | ^~~~~~~~ /usr/include/c++/14/cstddef:131:5: note: template argument deduction/substitution failed: a.cc:11:9: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^~~~ In file included from /usr/include/c++/14/string:55, from /usr/include/c++/14/bitset:52, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52: /usr/include/c++/14/bits/basic_string.tcc:835:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&)' 835 | operator>>(basic_istream<_CharT, _Traits>& __in, | ^~~~~~~~ /usr/include/c++/14/bits/basic_string.tcc:835:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/bitset:1597:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, bitset<_Nb>&)' 1597 | operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x) | ^~~~~~~~ /usr/include/c++/14/bitset:1597:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ In file included from /usr/include/c++/14/istream:1109, from /usr/include/c++/14/sstream:40, from /usr/include/c++/14/complex:45, from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127: /usr/include/c++/14/bits/istream.tcc:978:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT&)' 978 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c) | ^~~~~~~~ /usr/include/c++/14/bits/istream.tcc:978:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:849:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char&)' 849 | operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:849:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:854:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char&)' 854 | operator>>(basic_istream<char, _Traits>& __in, signed char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:854:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:896:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT*)' 896 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s) | ^~~~~~~~ /usr/include/c++/14/istream:896:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:939:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char*)' 939 | operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:939:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:945:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char*)' 945 | operator>>(basic_istream<char, _Traits>& __in, signed char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:945:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:1099:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/istream:1099:5: note: template argument deduction/substitution failed: /usr/include/c++/14/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = int]': a.cc:11:36: required from here 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/istream:1099:5: error: no type named 'type' in 'struct std::enable_if<false, void>' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: candidate: 'template<class _Tp, class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, complex<_Tp>&)' 509 | operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:143: /usr/include/c++/14/iomanip:76:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Resetiosflags)' 76 | operator>>(basic_istream<_CharT, _Traits>& __is, _Resetiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:76:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/iomanip:106:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setiosflags)' 106 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:106:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/iomanip:137:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setbase)' 137 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setbase __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:137:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> a.at(0) + x.at(0) + c.at(0) << endl; | ^ /usr/include/c++/14/i
s707018660
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string a , x , c; cin >> a >> x >> c ; cout >> 'A' + x.at(0) + 'C' << endl; }
a.cc: In function 'int main()': a.cc:11:14: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ~~~~ ^~ ~~~~~~~~~~~~~~~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:11:14: note: candidate: 'operator>>(int, int)' (built-in) 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ~~~~~^~~~~~~~~~~~~~~~~~~~~~ a.cc:11:14: note: no known conversion for argument 1 from 'std::ostream' {aka 'std::basic_ostream<char>'} to 'int' In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41, from a.cc:1: /usr/include/c++/14/cstddef:131:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(byte, _IntegerType)' 131 | operator>>(byte __b, _IntegerType __shift) noexcept | ^~~~~~~~ /usr/include/c++/14/cstddef:131:5: note: template argument deduction/substitution failed: a.cc:11:9: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~~ In file included from /usr/include/c++/14/string:55, from /usr/include/c++/14/bitset:52, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52: /usr/include/c++/14/bits/basic_string.tcc:835:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&)' 835 | operator>>(basic_istream<_CharT, _Traits>& __in, | ^~~~~~~~ /usr/include/c++/14/bits/basic_string.tcc:835:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/bitset:1597:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, bitset<_Nb>&)' 1597 | operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x) | ^~~~~~~~ /usr/include/c++/14/bitset:1597:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ In file included from /usr/include/c++/14/istream:1109, from /usr/include/c++/14/sstream:40, from /usr/include/c++/14/complex:45, from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127: /usr/include/c++/14/bits/istream.tcc:978:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT&)' 978 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c) | ^~~~~~~~ /usr/include/c++/14/bits/istream.tcc:978:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:849:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char&)' 849 | operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:849:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:854:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char&)' 854 | operator>>(basic_istream<char, _Traits>& __in, signed char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:854:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:896:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT*)' 896 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s) | ^~~~~~~~ /usr/include/c++/14/istream:896:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:939:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char*)' 939 | operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:939:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:945:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char*)' 945 | operator>>(basic_istream<char, _Traits>& __in, signed char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:945:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:1099:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/istream:1099:5: note: template argument deduction/substitution failed: /usr/include/c++/14/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = int]': a.cc:11:26: required from here 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/istream:1099:5: error: no type named 'type' in 'struct std::enable_if<false, void>' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: candidate: 'template<class _Tp, class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, complex<_Tp>&)' 509 | operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:143: /usr/include/c++/14/iomanip:76:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Resetiosflags)' 76 | operator>>(basic_istream<_CharT, _Traits>& __is, _Resetiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:76:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/iomanip:106:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setiosflags)' 106 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:106:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/iomanip:137:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setbase)' 137 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setbase __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:137:5: note: template argument deduction/substitution failed: a.cc:11:33: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> 'A' + x.at(0) + 'C' << endl; | ^~~ /usr/include/c++/14/iomanip:177:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setfill<_CharT>)' 177 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setfill<_CharT> __f
s745046386
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; getline(cin, s); cout << "A" + s.at(8) + "C" << endl; }
a.cc: In function 'int main()': a.cc:7:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | cout << "A" + s.at(8) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s701146584
p03860
C++
// lcmとか__builtin_popcountとかはg++ -std=c++17 default.cppみたいなかんじで #include <bits/stdc++.h> #define mod 1000000007 #define INF LLONG_MAX #define ll long long #define ln cout<<endl #define Yes cout<<"Yes"<<endl #define NO cout<<"NO"<<endl #define YES cout<<"YES"<<endl #define No cout<<"No"<<endl #define REP(i,m,n) for(ll i=(ll)(m);i<(ll)(n);i++) #define rep(i,n) REP(i,0,n) #define all(x) (x).begin(),(x).end() #define rall(x) (x).rbegin(),(x).rend() using namespace std; ll dx[4]={1,0,-1,0}; ll dy[4]={0,1,0,-1}; int main() { cin.tie(0); ios::sync_with_stdio(false); ll a,b,c,d,e,n,k,maxi=0,f=0,mini=INF,sum=0,q; string str,g,ko; ll x,y; cin>>str>>g>>ko; cout<<"A"<<g[0]<<"C"<<endl: return 0; }
a.cc: In function 'int main()': a.cc:28:31: error: expected ';' before ':' token 28 | cout<<"A"<<g[0]<<"C"<<endl: | ^ | ;
s968538324
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; cout << "A" + s.at(8) + "C" << endl; }
a.cc: In function 'int main()': a.cc:7:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | cout << "A" + s.at(8) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s918464664
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string a, b; cin >> a >> b; cout << "A" + b.at(0) + "C" << endl; }
a.cc: In function 'int main()': a.cc:9:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 9 | cout << "A" + b.at(0) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s845425591
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string A , x , C; cin >> A >> x >> C ; cout >> A.at(1) + x.at(1) + C.at(1) << endl; }
a.cc: In function 'int main()': a.cc:11:14: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ~~~~ ^~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:11:14: note: candidate: 'operator>>(int, int)' (built-in) 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ a.cc:11:14: note: no known conversion for argument 1 from 'std::ostream' {aka 'std::basic_ostream<char>'} to 'int' In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41, from a.cc:1: /usr/include/c++/14/cstddef:131:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(byte, _IntegerType)' 131 | operator>>(byte __b, _IntegerType __shift) noexcept | ^~~~~~~~ /usr/include/c++/14/cstddef:131:5: note: template argument deduction/substitution failed: a.cc:11:9: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^~~~ In file included from /usr/include/c++/14/string:55, from /usr/include/c++/14/bitset:52, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52: /usr/include/c++/14/bits/basic_string.tcc:835:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&)' 835 | operator>>(basic_istream<_CharT, _Traits>& __in, | ^~~~~~~~ /usr/include/c++/14/bits/basic_string.tcc:835:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/bitset:1597:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, bitset<_Nb>&)' 1597 | operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x) | ^~~~~~~~ /usr/include/c++/14/bitset:1597:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ In file included from /usr/include/c++/14/istream:1109, from /usr/include/c++/14/sstream:40, from /usr/include/c++/14/complex:45, from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127: /usr/include/c++/14/bits/istream.tcc:978:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT&)' 978 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c) | ^~~~~~~~ /usr/include/c++/14/bits/istream.tcc:978:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:849:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char&)' 849 | operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:849:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:854:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char&)' 854 | operator>>(basic_istream<char, _Traits>& __in, signed char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:854:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:896:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT*)' 896 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s) | ^~~~~~~~ /usr/include/c++/14/istream:896:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:939:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char*)' 939 | operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:939:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:945:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char*)' 945 | operator>>(basic_istream<char, _Traits>& __in, signed char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:945:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:1099:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/istream:1099:5: note: template argument deduction/substitution failed: /usr/include/c++/14/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = int]': a.cc:11:36: required from here 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/istream:1099:5: error: no type named 'type' in 'struct std::enable_if<false, void>' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: candidate: 'template<class _Tp, class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, complex<_Tp>&)' 509 | operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:143: /usr/include/c++/14/iomanip:76:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Resetiosflags)' 76 | operator>>(basic_istream<_CharT, _Traits>& __is, _Resetiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:76:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/iomanip:106:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setiosflags)' 106 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:106:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/iomanip:137:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setbase)' 137 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setbase __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:137:5: note: template argument deduction/substitution failed: a.cc:11:43: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 11 | cout >> A.at(1) + x.at(1) + C.at(1) << endl; | ^ /usr/include/c++/14/i
s832176573
p03860
C++
#include <bits/stdc++.h> using ll = long long; using namespace std; #define rep(i,n) for(int i=0, i##_len=(int)(n); i<i##_len; i++) #define reps(i,n) for(int i=1 , i##_len=(int)(n);i<=i##_len;i++) #define rrep(i,n) for(int i=((int)(n)-1);i>=0;i--) #define rreps(i,n) for(int i=((int)(n));i>0;i--) #define repi(i,x) for(auto i=(x).begin(),i##_fin=(x).end();i!=i##_fin;i++) #define all(x) (x).begin(), (x).end() #define F first #define S second #define mp make_pair #define pb push_back #define solve(a) ((a)?"Yes":"No") typedef vector<int> Vi; typedef vector<Vi> VVi; typedef pair<int , int> Pi; typedef vector<Pi> VPi; typedef vector<long long> V; typedef vector<V> VV; typedef pair<long long , long long> P; typedef vector<P> VP; template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1;} return 0;} template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1;} return 0;} const long long INFLL = 1LL<<60; const int INF = 1<<30; const double PI=acos(-1); int main(){ strng a,b,c; int ans=0; cin >>a>>b>>c; cout<<a[0]<<b[0]<<c[0]<<endl; }
a.cc: In function 'int main()': a.cc:29:1: error: 'strng' was not declared in this scope 29 | strng a,b,c; | ^~~~~ a.cc:31:15: error: 'a' was not declared in this scope 31 | cin >>a>>b>>c; | ^ a.cc:31:18: error: 'b' was not declared in this scope 31 | cin >>a>>b>>c; | ^ a.cc:31:21: error: 'c' was not declared in this scope 31 | cin >>a>>b>>c; | ^
s730921310
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string x; string ans = "A"; cin >> x; ans += x + "C" cout << ans << endl; }
a.cc: In function 'int main()': a.cc:8:19: error: expected ';' before 'cout' 8 | ans += x + "C" | ^ | ; 9 | cout << ans << endl; | ~~~~
s461223363
p03860
C++
#include <iostream> using namespace std; int main(){ string s; string t={}; int r=1; cin>>s; t[0]=s[0]; for(int i=1;i<s.length();i++){ if(s[i]==" "){ t[r]==s[i+1]; r++; } } cout<<t; }
a.cc: In function 'int main()': a.cc:11:24: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] 11 | if(s[i]==" "){
s432762945
p03860
C++
#include <iostream> using namespace std; int main(){ string s; string t={}; int r=1; cin>>s; t[0]=s[0]; for(i=1;i<s.length();i++){ if(s[i]==" "){ t[r]==s[i+1]; r++; } } cout<<t; }
a.cc: In function 'int main()': a.cc:10:13: error: 'i' was not declared in this scope 10 | for(i=1;i<s.length();i++){ | ^
s807330575
p03860
C++
#include <iostream> using namespace std; int main(){ string s; string t=[]; int r=1; cin>>s; t[0]=s[0]; for(i=1;i<s.length();i++){ if(s[i]==" "){ t[r]==s[i+1]; r++; } } }
a.cc: In lambda function: a.cc:6:20: error: expected '{' before ';' token 6 | string t=[]; | ^ a.cc: In function 'int main()': a.cc:6:18: error: conversion from 'main()::<lambda()>' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested 6 | string t=[]; | ^~ a.cc:10:13: error: 'i' was not declared in this scope 10 | for(i=1;i<s.length();i++){ | ^
s455887520
p03860
C++
#include <iostream> using namespace std; int main(){ string s; string t=[]; int r=1; t[0]=s[0]; cin>>s; for(i=1;i<s.length();i++){ if(s[i]==" "){ t[r]==s[i+1]; r++; } } }
a.cc: In lambda function: a.cc:6:20: error: expected '{' before ';' token 6 | string t=[]; | ^ a.cc: In function 'int main()': a.cc:6:18: error: conversion from 'main()::<lambda()>' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested 6 | string t=[]; | ^~ a.cc:10:13: error: 'i' was not declared in this scope 10 | for(i=1;i<s.length();i++){ | ^
s632179825
p03860
C++
#include<iostream> using namespace std; int main (){ string s, d; cin >> d >> s >> d; cout << "A" << str[0] << "C" << '\n'; }
a.cc: In function 'int main()': a.cc:7:18: error: 'str' was not declared in this scope; did you mean 'std'? 7 | cout << "A" << str[0] << "C" << '\n'; | ^~~ | std
s951074868
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string a, x ,b; cin >> a >> x >> b; cout << A << x.at(0) << B << endl; }
a.cc: In function 'int main()': a.cc:10:11: error: 'A' was not declared in this scope 10 | cout << A << x.at(0) << B << endl; | ^ a.cc:10:27: error: 'B' was not declared in this scope 10 | cout << A << x.at(0) << B << endl; | ^
s752823964
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; char x; s.at(0) = x; cout << A << x << C << endl; }
a.cc: In function 'int main()': a.cc:9:11: error: 'A' was not declared in this scope 9 | cout << A << x << C << endl; | ^ a.cc:9:21: error: 'C' was not declared in this scope 9 | cout << A << x << C << endl; | ^
s297317664
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); String name = ""; for(int i = 0;i<3;i++){ String a = sc.next(); name = name + a.subString(0,0); } System.out.println(name); } }
Main.java:9: error: cannot find symbol name = name + a.subString(0,0); ^ symbol: method subString(int,int) location: variable a of type String 1 error
s585711444
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); String name = ""; for(int i = 0;i<3;i++){ String a = sc.next(); name += a.subString(0,0); } System.out.println(name); } }
Main.java:9: error: cannot find symbol name += a.subString(0,0); ^ symbol: method subString(int,int) location: variable a of type String 1 error
s795117113
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string a,b,c; cin>>a>>b>>c; stirng n="A"; stirng m="C"; cout<<n+b.at(0)+m<<endl; }
a.cc: In function 'int main()': a.cc:7:3: error: 'stirng' was not declared in this scope 7 | stirng n="A"; | ^~~~~~ a.cc:8:9: error: expected ';' before 'm' 8 | stirng m="C"; | ^~ | ; a.cc:9:9: error: 'n' was not declared in this scope 9 | cout<<n+b.at(0)+m<<endl; | ^ a.cc:9:19: error: 'm' was not declared in this scope 9 | cout<<n+b.at(0)+m<<endl; | ^
s684829393
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string a,b,c; cin>>a>>b>>c; cout<<"A"+b.at(0)+"C"<<endl; }
a.cc: In function 'int main()': a.cc:7:20: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | cout<<"A"+b.at(0)+"C"<<endl; | ~~~~~~~~~~~^~~~ | | | | | const char [2] | const char*
s069444186
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string a,b,c; cin >> a >> b >> c; cout << "A"b.at(0) + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:11: error: unable to find string literal operator 'operator""b' with 'const char [2]', 'long unsigned int' arguments 8 | cout << "A"b.at(0) + "C" << endl; | ^~~~
s396240600
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string a,b,c; cin >> a >> b >> c; cout << 'A'b.at(0) + 'C' << endl; }
a.cc: In function 'int main()': a.cc:8:11: error: unable to find character literal operator 'operator""b' with 'char' argument 8 | cout << 'A'b.at(0) + 'C' << endl; | ^~~~
s203037271
p03860
C++
ソースコード Copy Copy #include <bits/stdc++.h> using namespace std; int main() { string a,b,c; cin >> a >> b >> c; cout << "A"b.at(0) + "C" << endl; }
a.cc:1:1: error: '\U000030bd\U000030fc\U000030b9\U000030b3\U000030fc\U000030c9' does not name a type 1 | ソースコード | ^~~~~~~~~~~~ In file included from /usr/include/c++/14/bits/stl_algobase.h:62, from /usr/include/c++/14/algorithm:60, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51, from a.cc:5: /usr/include/c++/14/ext/type_traits.h:164:35: error: 'constexpr const bool __gnu_cxx::__is_null_pointer' redeclared as different kind of entity 164 | __is_null_pointer(std::nullptr_t) | ^ /usr/include/c++/14/ext/type_traits.h:159:5: note: previous declaration 'template<class _Type> constexpr bool __gnu_cxx::__is_null_pointer(_Type)' 159 | __is_null_pointer(_Type) | ^~~~~~~~~~~~~~~~~ /usr/include/c++/14/ext/type_traits.h:164:26: error: 'nullptr_t' is not a member of 'std'; did you mean 'nullptr_t'? 164 | __is_null_pointer(std::nullptr_t) | ^~~~~~~~~ In file included from /usr/include/c++/14/cstddef:50, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41: /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:443:29: note: 'nullptr_t' declared here 443 | typedef decltype(nullptr) nullptr_t; | ^~~~~~~~~ In file included from /usr/include/c++/14/bits/stl_pair.h:60, from /usr/include/c++/14/bits/stl_algobase.h:64: /usr/include/c++/14/type_traits:666:33: error: 'nullptr_t' is not a member of 'std'; did you mean 'nullptr_t'? 666 | struct is_null_pointer<std::nullptr_t> | ^~~~~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:443:29: note: 'nullptr_t' declared here 443 | typedef decltype(nullptr) nullptr_t; | ^~~~~~~~~ /usr/include/c++/14/type_traits:666:42: error: template argument 1 is invalid 666 | struct is_null_pointer<std::nullptr_t> | ^ /usr/include/c++/14/type_traits:670:48: error: template argument 1 is invalid 670 | struct is_null_pointer<const std::nullptr_t> | ^ /usr/include/c++/14/type_traits:674:51: error: template argument 1 is invalid 674 | struct is_null_pointer<volatile std::nullptr_t> | ^ /usr/include/c++/14/type_traits:678:57: error: template argument 1 is invalid 678 | struct is_null_pointer<const volatile std::nullptr_t> | ^ /usr/include/c++/14/type_traits:1429:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 1429 | : public integral_constant<std::size_t, alignof(_Tp)> | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/type_traits:1429:57: error: template argument 1 is invalid 1429 | : public integral_constant<std::size_t, alignof(_Tp)> | ^ /usr/include/c++/14/type_traits:1429:57: note: invalid template non-type parameter /usr/include/c++/14/type_traits:1438:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 1438 | : public integral_constant<std::size_t, 0> { }; | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/type_traits:1438:46: error: template argument 1 is invalid 1438 | : public integral_constant<std::size_t, 0> { }; | ^ /usr/include/c++/14/type_traits:1438:46: note: invalid template non-type parameter /usr/include/c++/14/type_traits:1440:26: error: 'std::size_t' has not been declared 1440 | template<typename _Tp, std::size_t _Size> | ^~~ /usr/include/c++/14/type_traits:1441:21: error: '_Size' was not declared in this scope 1441 | struct rank<_Tp[_Size]> | ^~~~~ /usr/include/c++/14/type_traits:1441:27: error: template argument 1 is invalid 1441 | struct rank<_Tp[_Size]> | ^ /usr/include/c++/14/type_traits:1442:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 1442 | : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/type_traits:1442:65: error: template argument 1 is invalid 1442 | : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; | ^ /usr/include/c++/14/type_traits:1442:65: note: invalid template non-type parameter /usr/include/c++/14/type_traits:1446:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 1446 | : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/type_traits:1446:65: error: template argument 1 is invalid 1446 | : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; | ^ /usr/include/c++/14/type_traits:1446:65: note: invalid template non-type parameter /usr/include/c++/14/type_traits:2086:26: error: 'std::size_t' has not been declared 2086 | template<typename _Tp, std::size_t _Size> | ^~~ /usr/include/c++/14/type_traits:2087:30: error: '_Size' was not declared in this scope 2087 | struct remove_extent<_Tp[_Size]> | ^~~~~ /usr/include/c++/14/type_traits:2087:36: error: template argument 1 is invalid 2087 | struct remove_extent<_Tp[_Size]> | ^ /usr/include/c++/14/type_traits:2099:26: error: 'std::size_t' has not been declared 2099 | template<typename _Tp, std::size_t _Size> | ^~~ /usr/include/c++/14/type_traits:2100:35: error: '_Size' was not declared in this scope 2100 | struct remove_all_extents<_Tp[_Size]> | ^~~~~ /usr/include/c++/14/type_traits:2100:41: error: template argument 1 is invalid 2100 | struct remove_all_extents<_Tp[_Size]> | ^ /usr/include/c++/14/type_traits:2171:12: error: 'std::size_t' has not been declared 2171 | template<std::size_t _Len> | ^~~ /usr/include/c++/14/type_traits:2176:30: error: '_Len' was not declared in this scope 2176 | unsigned char __data[_Len]; | ^~~~ /usr/include/c++/14/type_traits:2194:12: error: 'std::size_t' has not been declared 2194 | template<std::size_t _Len, std::size_t _Align = | ^~~ /usr/include/c++/14/type_traits:2194:30: error: 'std::size_t' has not been declared 2194 | template<std::size_t _Len, std::size_t _Align = | ^~~ /usr/include/c++/14/type_traits:2195:55: error: '_Len' was not declared in this scope 2195 | __alignof__(typename __aligned_storage_msa<_Len>::__type)> | ^~~~ /usr/include/c++/14/type_traits:2195:59: error: template argument 1 is invalid 2195 | __alignof__(typename __aligned_storage_msa<_Len>::__type)> | ^ /usr/include/c++/14/type_traits:2202:30: error: '_Len' was not declared in this scope 2202 | unsigned char __data[_Len]; | ^~~~ /usr/include/c++/14/type_traits:2203:44: error: '_Align' was not declared in this scope 2203 | struct __attribute__((__aligned__((_Align)))) { } __align; | ^~~~~~ In file included from /usr/include/c++/14/bits/stl_tempbuf.h:59, from /usr/include/c++/14/bits/stl_algo.h:69, from /usr/include/c++/14/algorithm:61: /usr/include/c++/14/new:131:26: error: declaration of 'operator new' as non-function 131 | _GLIBCXX_NODISCARD void* operator new(std::size_t) _GLIBCXX_THROW (std::bad_alloc) | ^~~~~~~~ /usr/include/c++/14/new:131:44: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 131 | _GLIBCXX_NODISCARD void* operator new(std::size_t) _GLIBCXX_THROW (std::bad_alloc) | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/new:132:41: error: attributes after parenthesized initializer ignored [-fpermissive] 132 | __attribute__((__externally_visible__)); | ^ /usr/include/c++/14/new:133:26: error: declaration of 'operator new []' as non-function 133 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc) | ^~~~~~~~ /usr/include/c++/14/new:133:46: error: 'size_t' is not a member of 'std'; did you mean 'size_t'? 133 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc) | ^~~~~~ /usr/lib/gcc/x86_64-linux-gnu/14/include/stddef.h:214:23: note: 'size_t' declared here 214 | typedef __SIZE_TYPE__ size_t; | ^~~~~~ /usr/include/c++/14/new:134:41: error: attributes after parenthesized initializer ignored [-fpermissive] 134 | __attribute__((__exter
s849056373
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string a,b,c; cin >> a >> b >> c; cout << 'A'b.at(0) + 'C' << endl; }
a.cc: In function 'int main()': a.cc:8:11: error: unable to find character literal operator 'operator""b' with 'char' argument 8 | cout << 'A'b.at(0) + 'C' << endl; | ^~~~
s131166377
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; cout << "A"s.at(0)"C" << endl; return 0; }
a.cc: In function 'int main()': a.cc:8:21: error: expected ';' before string constant 8 | cout << "A"s.at(0)"C" << endl; | ^~~ | ;
s435510660
p03860
C++
#include <bits/stdc++.h> #define _GLIBCXX_DEBUG #define rep(i,n) for(int i=0;i<(n);++i) #define repi(i,a,b) for(int i=int(a);i<int(b);++i) #define all(x) (x).begin(), (x).end() using namespace std; int main() { string a,b,c; cin>>a>>b>>c; cout>>a[0]>>b[0]>>c[0]>>endl; }
a.cc: In function 'int main()': a.cc:10:9: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'}) 10 | cout>>a[0]>>b[0]>>c[0]>>endl; a.cc:10:9: note: candidate: 'operator>>(int, int)' (built-in) a.cc:10:9: note: no known conversion for argument 1 from 'std::ostream' {aka 'std::basic_ostream<char>'} to 'int' In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41, from a.cc:1: /usr/include/c++/14/cstddef:131:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(byte, _IntegerType)' 131 | operator>>(byte __b, _IntegerType __shift) noexcept | ^~~~~~~~ /usr/include/c++/14/cstddef:131:5: note: template argument deduction/substitution failed: a.cc:10:5: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^~~~ In file included from /usr/include/c++/14/string:55, from /usr/include/c++/14/bitset:52, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52: /usr/include/c++/14/bits/basic_string.tcc:835:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&)' 835 | operator>>(basic_istream<_CharT, _Traits>& __in, | ^~~~~~~~ /usr/include/c++/14/bits/basic_string.tcc:835:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/bitset:1597:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, bitset<_Nb>&)' 1597 | operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x) | ^~~~~~~~ /usr/include/c++/14/bitset:1597:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ In file included from /usr/include/c++/14/istream:1109, from /usr/include/c++/14/sstream:40, from /usr/include/c++/14/complex:45, from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127: /usr/include/c++/14/bits/istream.tcc:978:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT&)' 978 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c) | ^~~~~~~~ /usr/include/c++/14/bits/istream.tcc:978:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:849:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char&)' 849 | operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:849:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:854:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char&)' 854 | operator>>(basic_istream<char, _Traits>& __in, signed char& __c) | ^~~~~~~~ /usr/include/c++/14/istream:854:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:896:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT*)' 896 | operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s) | ^~~~~~~~ /usr/include/c++/14/istream:896:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:939:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char*)' 939 | operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:939:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:945:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char*)' 945 | operator>>(basic_istream<char, _Traits>& __in, signed char* __s) | ^~~~~~~~ /usr/include/c++/14/istream:945:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:1099:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/istream:1099:5: note: template argument deduction/substitution failed: /usr/include/c++/14/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = char&]': a.cc:10:14: required from here 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/istream:1099:5: error: no type named 'type' in 'struct std::enable_if<false, void>' 1099 | operator>>(_Istream&& __is, _Tp&& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: candidate: 'template<class _Tp, class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, complex<_Tp>&)' 509 | operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) | ^~~~~~~~ /usr/include/c++/14/complex:509:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:143: /usr/include/c++/14/iomanip:76:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Resetiosflags)' 76 | operator>>(basic_istream<_CharT, _Traits>& __is, _Resetiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:76:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/iomanip:106:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setiosflags)' 106 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setiosflags __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:106:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/iomanip:137:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setbase)' 137 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setbase __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:137:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/iomanip:177:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setfill<_CharT>)' 177 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setfill<_CharT> __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:177:5: note: template argument deduction/substitution failed: a.cc:10:14: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>' 10 | cout>>a[0]>>b[0]>>c[0]>>endl; | ^ /usr/include/c++/14/iomanip:207:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _Setprecision)' 207 | operator>>(basic_istream<_CharT, _Traits>& __is, _Setprecision __f) | ^~~~~~~~ /usr/include/c++/14/iomanip:207:5: note: template
s907335199
p03860
C++
#include <bits/stdc++.h> using namespace std; int main () { string Atcoder, s, Contest; cin >> Atcoder >> s >> Contest; char p=s.at(0); cout << "A"+p+"C" << endl; }
a.cc: In function 'int main()': a.cc:10:18: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 10 | cout << "A"+p+"C" << endl; | ~~~~~^~~~ | | | | | const char [2] | const char*
s504105886
p03860
C++
#include <bits/stdc++.h> using namespace std; int main () { string s; cin >> Atcoder s Contest; char p=s.at(0); cout << A+p+C << endl; }
a.cc: In function 'int main()': a.cc:6:12: error: 'Atcoder' was not declared in this scope 6 | cin >> Atcoder s Contest; | ^~~~~~~ a.cc:10:13: error: 'A' was not declared in this scope 10 | cout << A+p+C << endl; | ^ a.cc:10:17: error: 'C' was not declared in this scope 10 | cout << A+p+C << endl; | ^
s114248050
p03860
C++
#include<iostream> using namespace std; int main() { int s1,s2,s3; cin>>s1>>s2>>s3; cout<<s1[0]<<s2[0]<<s3[0]<<endl; return 0; }
a.cc: In function 'int main()': a.cc:7:11: error: invalid types 'int[int]' for array subscript 7 | cout<<s1[0]<<s2[0]<<s3[0]<<endl; | ^ a.cc:7:18: error: invalid types 'int[int]' for array subscript 7 | cout<<s1[0]<<s2[0]<<s3[0]<<endl; | ^ a.cc:7:25: error: invalid types 'int[int]' for array subscript 7 | cout<<s1[0]<<s2[0]<<s3[0]<<endl; | ^
s929817653
p03860
C++
#include<iostream> using namespace std; int main(); { string s1,s2,s3; cin>>s1>>s2>>s3; cout<<s1[0]<<s2[0]<<s3[0]<<endl; return 0; }
a.cc:4:1: error: expected unqualified-id before '{' token 4 | { | ^
s226128881
p03860
C++
#include<iostream> using namespace std; int main() { string s; cin>>s; cout<<s[0]<<s[8]<<s[s.length()-7<<endl; return 0; }
a.cc: In function 'int main()': a.cc:7:35: error: invalid operands of types 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} and '<unresolved overloaded function type>' to binary 'operator<<' 7 | cout<<s[0]<<s[8]<<s[s.length()-7<<endl; | ~~~~~~~~~~~~^~~~~~ a.cc:7:41: error: expected ']' before ';' token 7 | cout<<s[0]<<s[8]<<s[s.length()-7<<endl; | ^ | ]
s601430146
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string s, at; cin >> at >> s; cout << "A" + s.at(0) + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 8 | cout << "A" + s.at(0) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s688663659
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string s, at; cin >> at >> s; cout << A + s.at(0) + C << endl; }
a.cc: In function 'int main()': a.cc:8:11: error: 'A' was not declared in this scope 8 | cout << A + s.at(0) + C << endl; | ^ a.cc:8:25: error: 'C' was not declared in this scope 8 | cout << A + s.at(0) + C << endl; | ^
s184556567
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); String a = sc.next(); String b = sc.next(); String c = sc.next(); b = (String)b.charAt(0); System.out.println("A" + b + "C"); } }
Main.java:11: error: incompatible types: char cannot be converted to String b = (String)b.charAt(0); ^ 1 error
s082112660
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); String a = sc.next(); String b = sc.next(); String c = sc.next(); b = b.charAt(0); System.out.println("A" + b + "C"); } }
Main.java:11: error: incompatible types: char cannot be converted to String b = b.charAt(0); ^ 1 error
s470388360
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); String a = sc.nextString(); String b = sc.nextString(); String c = sc.nextString(); b = b.charAt(0); System.out.println("A" + b + "C"); } }
Main.java:8: error: cannot find symbol String a = sc.nextString(); ^ symbol: method nextString() location: variable sc of type Scanner Main.java:9: error: cannot find symbol String b = sc.nextString(); ^ symbol: method nextString() location: variable sc of type Scanner Main.java:10: error: cannot find symbol String c = sc.nextString(); ^ symbol: method nextString() location: variable sc of type Scanner Main.java:11: error: incompatible types: char cannot be converted to String b = b.charAt(0); ^ 4 errors
s088697186
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); String a = sc.nextInt(); String b = sc.nextInt(); String c = sc.nextInt(); b = b.charAt(0); System.out.println("A" + b + "C"); } }
Main.java:8: error: incompatible types: int cannot be converted to String String a = sc.nextInt(); ^ Main.java:9: error: incompatible types: int cannot be converted to String String b = sc.nextInt(); ^ Main.java:10: error: incompatible types: int cannot be converted to String String c = sc.nextInt(); ^ Main.java:11: error: incompatible types: char cannot be converted to String b = b.charAt(0); ^ 4 errors
s880477842
p03860
C++
#include <iostream> using namespace std; int main(void){ cin >> a >> b >> c; cout << a[0] << b[0] << c[0] << endl; }
a.cc: In function 'int main()': a.cc:4:10: error: 'a' was not declared in this scope 4 | cin >> a >> b >> c; | ^ a.cc:4:15: error: 'b' was not declared in this scope 4 | cin >> a >> b >> c; | ^ a.cc:4:20: error: 'c' was not declared in this scope 4 | cin >> a >> b >> c; | ^
s507092253
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; char x = S.at(8); cout << "A" + x + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:19: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 8 | cout << "A" + x + "C" << endl; | ~~~~~~~ ^ ~~~ | | | | | const char [2] | const char*
s096503432
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; char x = S.at(8); cout << "A" + x + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:19: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 8 | cout << "A" + x + "C" << endl; | ~~~~~~~ ^ ~~~ | | | | | const char [2] | const char*
s093729186
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; char x = S.at(0); cout << "AtCoder " + x + " Contest" << endl; }
a.cc: In function 'int main()': a.cc:8:26: error: invalid operands of types 'const char*' and 'const char [9]' to binary 'operator+' 8 | cout << "AtCoder " + x + " Contest" << endl; | ~~~~~~~~~~~~~~ ^ ~~~~~~~~~~ | | | | | const char [9] | const char*
s009425560
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string str1, str2 ,str3; cin >> str1 >> str2 >> str3; cout << A + str2.at(0) + C << endl; }
a.cc: In function 'int main()': a.cc:7:11: error: 'A' was not declared in this scope 7 | cout << A + str2.at(0) + C << endl; | ^ a.cc:7:28: error: 'C' was not declared in this scope 7 | cout << A + str2.at(0) + C << endl; | ^
s495740793
p03860
C++
int main() { string A, B, C; string ans; cin >> A >> B >> C; ans.at(0) = A.at(0); ans.at(1) = B.at(0); ans.at(2) = C.at(0); cout << ans << endl; return 0; }
a.cc: In function 'int main()': a.cc:3:9: error: 'string' was not declared in this scope 3 | string A, B, C; | ^~~~~~ a.cc:4:15: error: expected ';' before 'ans' 4 | string ans; | ^~~~ | ; a.cc:6:9: error: 'cin' was not declared in this scope 6 | cin >> A >> B >> C; | ^~~ a.cc:6:16: error: 'A' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:21: error: 'B' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:26: error: 'C' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:7:9: error: 'ans' was not declared in this scope 7 | ans.at(0) = A.at(0); | ^~~ a.cc:10:9: error: 'cout' was not declared in this scope 10 | cout << ans << endl; | ^~~~ a.cc:10:24: error: 'endl' was not declared in this scope 10 | cout << ans << endl; | ^~~~
s336781217
p03860
C++
int main() { string A, B, C; string ans; cin >> A >> B >> C; ans.at(0) = A.at(0); ans.at(1) = B.at(0); ans.at(2) = C.at(0); cout << ans << endl; return 0; }
a.cc: In function 'int main()': a.cc:3:9: error: 'string' was not declared in this scope 3 | string A, B, C; | ^~~~~~ a.cc:4:15: error: expected ';' before 'ans' 4 | string ans; | ^~~~ | ; a.cc:6:9: error: 'cin' was not declared in this scope 6 | cin >> A >> B >> C; | ^~~ a.cc:6:16: error: 'A' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:21: error: 'B' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:26: error: 'C' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:7:9: error: 'ans' was not declared in this scope 7 | ans.at(0) = A.at(0); | ^~~ a.cc:10:9: error: 'cout' was not declared in this scope 10 | cout << ans << endl; | ^~~~ a.cc:10:24: error: 'endl' was not declared in this scope 10 | cout << ans << endl; | ^~~~
s091846977
p03860
C++
int main() { string A, B, C; string ans ;//= "000"; cin >> A >> B >> C; ans.at(0) = A.at(0); ans.at(1) = B.at(0); ans.at(2) = C.at(0); cout << ans << endl; return 0; }
a.cc: In function 'int main()': a.cc:3:9: error: 'string' was not declared in this scope 3 | string A, B, C; | ^~~~~~ a.cc:4:15: error: expected ';' before 'ans' 4 | string ans ;//= "000"; | ^~~~ | ; a.cc:6:9: error: 'cin' was not declared in this scope 6 | cin >> A >> B >> C; | ^~~ a.cc:6:16: error: 'A' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:21: error: 'B' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:6:26: error: 'C' was not declared in this scope 6 | cin >> A >> B >> C; | ^ a.cc:7:9: error: 'ans' was not declared in this scope 7 | ans.at(0) = A.at(0); | ^~~ a.cc:10:9: error: 'cout' was not declared in this scope 10 | cout << ans << endl; | ^~~~ a.cc:10:24: error: 'endl' was not declared in this scope 10 | cout << ans << endl; | ^~~~
s279791369
p03860
C++
#include<bits/stdc++.h> using namespace std; int main(){ string s1,s2,s3; cin >> s1 >> s2 >> s3; cout << "A" << s2.at(0) << "C" endl; }
a.cc: In function 'int main()': a.cc:5:33: error: expected ';' before 'endl' 5 | cout << "A" << s2.at(0) << "C" endl; | ^~~~~ | ;
s106781159
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { int A,B,C; cin >> A >> B >> C; cout << A.at(0) << B.at(0) << C.at(0) << endl; }
a.cc: In function 'int main()': a.cc:7:13: error: request for member 'at' in 'A', which is of non-class type 'int' 7 | cout << A.at(0) << B.at(0) << C.at(0) << endl; | ^~ a.cc:7:24: error: request for member 'at' in 'B', which is of non-class type 'int' 7 | cout << A.at(0) << B.at(0) << C.at(0) << endl; | ^~ a.cc:7:35: error: request for member 'at' in 'C', which is of non-class type 'int' 7 | cout << A.at(0) << B.at(0) << C.at(0) << endl; | ^~
s787301429
p03860
C++
#include<bits/stdc++.h> #define yes cout<<"Yes"<<endl; #define no cout<<"No"<<endl; #define ll long long int using namespace std; int main() { ll tc; ll a,b,c,n,x,y,z,cnt=0,sum=0; string str,str1,str1; int flag; cin>>str>>str1>>str2; cout<<str[0]<<str1[1]<<str2[0]<<endl; }
a.cc: In function 'int main()': a.cc:10:21: error: redeclaration of 'std::string str1' 10 | string str,str1,str1; | ^~~~ a.cc:10:16: note: 'std::string str1' previously declared here 10 | string str,str1,str1; | ^~~~ a.cc:12:21: error: 'str2' was not declared in this scope; did you mean 'str1'? 12 | cin>>str>>str1>>str2; | ^~~~ | str1
s442790356
p03860
Java
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); String a = sc.next(); String x = sc.next(); String c = sc.next(); System.out.println(a+x[0]+c); } }
Main.java:9: error: array required, but String found System.out.println(a+x[0]+c); ^ 1 error
s384334884
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S,A; cin >> A >> S >> A; cout << "A" + S.at(0) + "C" << endl; }
a.cc: In function 'int main()': a.cc:7:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | cout << "A" + S.at(0) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s681895359
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; cout << "A" + s.at(8) + "C" << endl; }
a.cc: In function 'int main()': a.cc:8:25: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 8 | cout << "A" + s.at(8) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s131501589
p03860
C++
#include <bits/stdc++.h> using namespace std; #define rep(i,n) for(int i = 0; i < (n); ++i) #define ll long long const ll mod = 1e9+7; const ll INF = 1e18; const double pi = acos(-1); ll modmul(ll a,ll b,ll mod){ return a%mod * (b%mod) %mod; } ll modpow(ll a,ll b,ll mod){ if(b==0) return 1; else if(b%2==0) return modpow(modmul(a,a,mod),b/2,mod); else return modmul(modpow(a,b-1,mod),a,mod); } ll moddiv(ll a,ll b,ll mod){ return a%mod * modpow(b,mod-2,mod) %mod; } int main(void) { string a,b,c; cin>>a>>b>>c; cour<<'A'<<b[0]<<'C'<<endl; return 0; }
a.cc: In function 'int main()': a.cc:27:5: error: 'cour' was not declared in this scope 27 | cour<<'A'<<b[0]<<'C'<<endl; | ^~~~
s212718672
p03860
C++
#include <iostream> #include <string> using namespace std; int main(){ string a, b, c, hen; cin >> a >> b >> c; hen = toupper(b[0]) cout << a[0] << hen << c[0] << endl; }
a.cc: In function 'int main()': a.cc:7:24: error: expected ';' before 'cout' 7 | hen = toupper(b[0]) | ^ | ; 8 | cout << a[0] << hen << c[0] << endl; | ~~~~
s904984735
p03860
C++
#include <iostream> #include <algorithm> using namespace std{ string a, b; cin >> a>> b; cout<<"A"<<b[0]<<"C"<<endl; }
a.cc:3:20: error: expected ';' before '{' token 3 | using namespace std{ | ^ | ; a.cc:3:20: error: expected unqualified-id before '{' token
s656597071
p03860
C++
#include <iostream> #include <algorithm> using namespace std;{ string a, b; cin >> a>> b; cout<<"A"<<b[0]<<"C"<<endl; }
a.cc:3:21: error: expected unqualified-id before '{' token 3 | using namespace std;{ | ^
s990044027
p03860
C++
#include <iostream> #include <string> using namespace std; int main(){ string a, b, c, hen; cin >> a >> b >> c; hen = (int)b[0] - 0x20; cout << a[0] << (char)hen << c[0] << endl; }
a.cc: In function 'int main()': a.cc:8:21: error: invalid cast from type 'std::string' {aka 'std::__cxx11::basic_string<char>'} to type 'char' 8 | cout << a[0] << (char)hen << c[0] << endl; | ^~~~~~~~~
s855141063
p03860
C++
#include <iostream> #include <string> using namespace std; int main(){ string a, b, c, hen; cin >> a >> b >> c; hen = (int)b[0] - 0x20 cout << a[0] << (char)hen << c[0] << endl; }
a.cc: In function 'int main()': a.cc:7:27: error: expected ';' before 'cout' 7 | hen = (int)b[0] - 0x20 | ^ | ; 8 | cout << a[0] << (char)hen << c[0] << endl; | ~~~~
s893839763
p03860
C++
#include <iostream> #include <string> using namespace std; int main(){ string a, b, c; cin >> a >> b >> c; hen = (int)b[0] - 0x20 cout << a[0] << (char)hen << c[0] << endl; }
a.cc: In function 'int main()': a.cc:7:5: error: 'hen' was not declared in this scope 7 | hen = (int)b[0] - 0x20 | ^~~
s572201813
p03860
C++
#include <iostream> #include <string> using namespace std; int main(){ string = a, b, c; cin >> a >> b >> c; a = a[0]; b = b[0] - 0x20; c = c[0]; cout << a+b+c << endl; }
a.cc: In function 'int main()': a.cc:5:12: error: expected unqualified-id before '=' token 5 | string = a, b, c; | ^ a.cc:6:12: error: 'a' was not declared in this scope 6 | cin >> a >> b >> c; | ^ a.cc:6:17: error: 'b' was not declared in this scope 6 | cin >> a >> b >> c; | ^ a.cc:6:22: error: 'c' was not declared in this scope 6 | cin >> a >> b >> c; | ^
s234637956
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { int s; cin >> s >> s; cout << s.at(0) << endl; }
a.cc: In function 'int main()': a.cc:8:13: error: request for member 'at' in 's', which is of non-class type 'int' 8 | cout << s.at(0) << endl; | ^~
s770564610
p03860
C++
#include<bits/stdc++.h> using namespace std; int main(){ string x; cin>>x; cout<<"AtCoder"<<""<<x.at(0)<<""<<Contest<<endl; }
a.cc: In function 'int main()': a.cc:8:35: error: 'Contest' was not declared in this scope; did you mean 'const'? 8 | cout<<"AtCoder"<<""<<x.at(0)<<""<<Contest<<endl; | ^~~~~~~ | const
s337520383
p03860
C++
#include <bits/stdc++.h> using namespace std; // ------------------- // ここから先は変更しない // ------------------- int main() { string name; cin >>name; cout << "A"+name[8]+"C" << endl; }
a.cc: In function 'int main()': a.cc:11:24: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 11 | cout << "A"+name[8]+"C" << endl; | ^~~~ | | | const char [2]
s703940099
p03860
C++
#include <bits/stdc++.h> using namespace std; // ------------------- // ここから先は変更しない // ------------------- int main() { string name; cin >>name; cout << "A"+str[8]+"C" << endl; }
a.cc: In function 'int main()': a.cc:11:17: error: 'str' was not declared in this scope; did you mean 'std'? 11 | cout << "A"+str[8]+"C" << endl; | ^~~ | std
s889531666
p03860
C++
#include <bits/stdc++.h> using namespace std; // ------------------- // ここから先は変更しない // ------------------- int main() { string name,; cin >>name; cout << "A"+name[8]+"C" << endl; }
a.cc: In function 'int main()': a.cc:8:21: error: expected unqualified-id before ';' token 8 | string name,; | ^ a.cc:11:24: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 11 | cout << "A"+name[8]+"C" << endl; | ^~~~ | | | const char [2]
s267838194
p03860
C++
#include <bits/stdc++.h> using namespace std; // ------------------- // ここから先は変更しない // ------------------- int main() { string name,; cin >>name; cout << "A"+str[8]+"C" << endl; }
a.cc: In function 'int main()': a.cc:8:21: error: expected unqualified-id before ';' token 8 | string name,; | ^ a.cc:11:17: error: 'str' was not declared in this scope; did you mean 'std'? 11 | cout << "A"+str[8]+"C" << endl; | ^~~ | std
s741626682
p03860
C++
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) using ll = long long; using P = pair<int,string>; int main() { string s,t,u; cin >> s >>t >> u; cout << A << t.at(0) << C << endl; }
a.cc: In function 'int main()': a.cc:10:9: error: 'A' was not declared in this scope 10 | cout << A << t.at(0) << C << endl; | ^ a.cc:10:25: error: 'C' was not declared in this scope 10 | cout << A << t.at(0) << C << endl; | ^
s675243571
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string s; cin >> s; cout << 'A' s.at(1) 'C' << endl; }
a.cc: In function 'int main()': a.cc:7:14: error: expected ';' before 's' 7 | cout << 'A' s.at(1) 'C' << endl; | ^~ | ;
s920053382
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string= a,b,c; cin>>a>>b>>c; cout<<a.at(0)<<b.at(0)<<c.at(0)<<endl; }
a.cc: In function 'int main()': a.cc:5:9: error: expected unqualified-id before '=' token 5 | string= a,b,c; | ^ a.cc:6:9: error: 'a' was not declared in this scope 6 | cin>>a>>b>>c; | ^ a.cc:6:12: error: 'b' was not declared in this scope 6 | cin>>a>>b>>c; | ^ a.cc:6:15: error: 'c' was not declared in this scope 6 | cin>>a>>b>>c; | ^
s105011772
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string= a,b,c; cin>>a>>b>>c; cout<<a.at(1)<<b.at(1)<<c.at(1)<<endl; }
a.cc: In function 'int main()': a.cc:5:9: error: expected unqualified-id before '=' token 5 | string= a,b,c; | ^ a.cc:6:9: error: 'a' was not declared in this scope 6 | cin>>a>>b>>c; | ^ a.cc:6:12: error: 'b' was not declared in this scope 6 | cin>>a>>b>>c; | ^ a.cc:6:15: error: 'c' was not declared in this scope 6 | cin>>a>>b>>c; | ^
s545347301
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string A,B,C; cin>>A>>B>>C cout<<A.at(1)<<B.at(1)<<C.at(1)<<endl; }
a.cc: In function 'int main()': a.cc:6:15: error: expected ';' before 'cout' 6 | cin>>A>>B>>C | ^ | ; 7 | 8 | cout<<A.at(1)<<B.at(1)<<C.at(1)<<endl; | ~~~~
s784706355
p03860
C++
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) int main(){ string a, b, c; cin >> a >> b >> c; cout << "A" + b.at(0) + "C" << endl; }
a.cc: In function 'int main()': a.cc:9:27: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 9 | cout << "A" + b.at(0) + "C" << endl; | ~~~~~~~~~~~~~ ^ ~~~ | | | | const char* const char [2]
s831287598
p03860
C++
#include <iostream> using namespace std; int main() { stirng a, b, c; cin >> a >> b >> c; cout << "A" << b[0] << "C"; }
a.cc: In function 'int main()': a.cc:5:3: error: 'stirng' was not declared in this scope 5 | stirng a, b, c; | ^~~~~~ a.cc:6:10: error: 'a' was not declared in this scope 6 | cin >> a >> b >> c; | ^ a.cc:6:15: error: 'b' was not declared in this scope 6 | cin >> a >> b >> c; | ^ a.cc:6:20: error: 'c' was not declared in this scope 6 | cin >> a >> b >> c; | ^
s421094968
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { for (int i = 0; i < 3; i++) { string c; cin >> c; string a; a += c.at(0); } cout << a << endl; }
a.cc: In function 'int main()': a.cc:11:11: error: 'a' was not declared in this scope 11 | cout << a << endl; | ^
s038845480
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string c; cin >> c; cout << 'A' + c.at(8) + 'C' << endl; } }
a.cc:9:1: error: expected declaration before '}' token 9 | } | ^
s961109708
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { for (int i = 0; i < 3; i++) { string c; cin >> c; I = c.at(0) cout << I << endl; }
a.cc: In function 'int main()': a.cc:8:5: error: 'I' was not declared in this scope 8 | I = c.at(0) | ^ a.cc:10:2: error: expected '}' at end of input 10 | } | ^ a.cc:4:12: note: to match this '{' 4 | int main() { | ^
s216889447
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { for (int i = 0; i < 3; i++) { string c; cin >> c; cout << c.at(0) << endl; }
a.cc: In function 'int main()': a.cc:9:2: error: expected '}' at end of input 9 | } | ^ a.cc:4:12: note: to match this '{' 4 | int main() { | ^
s466405487
p03860
C++
#include<iostream> #include<algorithm> #include<cmath> #include<vector> #include<map> #include<set> #include<string> #define fast_io ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); using namespace std; //inline int read(){int t = 0;int neg=1;char c;while((c=getchar_unlocked())!='\n'&&c!=' '&&c!=EOF){if(c=='-'){neg=-1;continue;}t=t*10+c-48;}return neg*t;} //inline int readl(){long long t = 0;long long neg=1ll;char c;while((c=getchar_unlocked())!='\n'&&c!=' '&&c!=EOF){if(c=='-'){neg=-1ll;continue;}t=t*10+c-48;}return neg*t;} #define debug(x) cout<<(#x)<<"="<<(x)<<", "; #define debug1(x) debug(x) cout<<'\n'; #define debug2(x1, x2) debug(x1) debug(x2) cout<<'\n'; #define debug3(x1, x2, x3) debug(x1) debug(x2) debug(x3) cout<<'\n'; #define debug4(x1, x2, x3, x4) debug(x1) debug(x2) debug(x3) debug(x4) cout<<'\n'; #define debug5(x1, x2, x3, x4, x5) debug(x1) debug(x2) debug(x3) debug(x4) debug(x5) cout<<'\n'; typedef long long int lli; typedef unsigned long long int ulli; typedef pair<int,int> pi; typedef pair<lli,lli> plli; typedef vector<int> vi; typedef vector<lli> vlli; typedef vector<pi> vpi; typedef vector<plli> vplli; const lli M=1000000007ll; int main(){ fast_io string s;.cin>>s>>s; cout<<"A"<<s[0]<<"C"; return 0; }
a.cc: In function 'int main()': a.cc:35:18: error: expected primary-expression before '.' token 35 | string s;.cin>>s>>s; | ^
s081869507
p03860
C++
#include<bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<ll> vec; typedef vector<vec> mat; typedef pair<ll,ll> pll; const ll mod=1e9+7; //const ll mod=998244353; const ll inf=1LL<<61; int main() { vector<string> s(3); for(ll i=0;i<3;i++) { cin >> s[i]; } cout << "A" << char(s[1]-'a'+'A') << "C" << endl; }
a.cc: In function 'int main()': a.cc:16:27: error: no match for 'operator-' (operand types are '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} and 'char') 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; In file included from /usr/include/c++/14/bits/stl_algobase.h:67, from /usr/include/c++/14/algorithm:60, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51, from a.cc:1: /usr/include/c++/14/bits/stl_iterator.h:618:5: note: candidate: 'template<class _IteratorL, class _IteratorR> constexpr decltype ((__y.base() - __x.base())) std::operator-(const reverse_iterator<_Iterator>&, const reverse_iterator<_IteratorR>&)' 618 | operator-(const reverse_iterator<_IteratorL>& __x, | ^~~~~~~~ /usr/include/c++/14/bits/stl_iterator.h:618:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::reverse_iterator<_Iterator>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/bits/stl_iterator.h:1790:5: note: candidate: 'template<class _IteratorL, class _IteratorR> constexpr decltype ((__x.base() - __y.base())) std::operator-(const move_iterator<_IteratorL>&, const move_iterator<_IteratorR>&)' 1790 | operator-(const move_iterator<_IteratorL>& __x, | ^~~~~~~~ /usr/include/c++/14/bits/stl_iterator.h:1790:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::move_iterator<_IteratorL>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ In file included from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127: /usr/include/c++/14/complex:370:5: note: candidate: 'template<class _Tp> std::complex<_Tp> std::operator-(const complex<_Tp>&, const complex<_Tp>&)' 370 | operator-(const complex<_Tp>& __x, const complex<_Tp>& __y) | ^~~~~~~~ /usr/include/c++/14/complex:370:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::complex<_Tp>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/complex:379:5: note: candidate: 'template<class _Tp> std::complex<_Tp> std::operator-(const complex<_Tp>&, const _Tp&)' 379 | operator-(const complex<_Tp>& __x, const _Tp& __y) | ^~~~~~~~ /usr/include/c++/14/complex:379:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::complex<_Tp>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/complex:388:5: note: candidate: 'template<class _Tp> std::complex<_Tp> std::operator-(const _Tp&, const complex<_Tp>&)' 388 | operator-(const _Tp& __x, const complex<_Tp>& __y) | ^~~~~~~~ /usr/include/c++/14/complex:388:5: note: template argument deduction/substitution failed: a.cc:16:28: note: mismatched types 'const std::complex<_Tp>' and 'char' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/complex:465:5: note: candidate: 'template<class _Tp> std::complex<_Tp> std::operator-(const complex<_Tp>&)' 465 | operator-(const complex<_Tp>& __x) | ^~~~~~~~ /usr/include/c++/14/complex:465:5: note: candidate expects 1 argument, 2 provided In file included from /usr/include/c++/14/valarray:605, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:166: /usr/include/c++/14/bits/valarray_after.h:406:5: note: candidate: 'template<class _Dom1, class _Dom2> std::_Expr<std::__detail::_BinClos<std::__minus, std::_Expr, std::_Expr, _Dom1, _Dom2>, typename std::__fun<std::__minus, typename _Dom1::value_type>::result_type> std::operator-(const _Expr<_Dom1, typename _Dom1::value_type>&, const _Expr<_Dom2, typename _Dom2::value_type>&)' 406 | _DEFINE_EXPR_BINARY_OPERATOR(-, struct std::__minus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__minus, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename std::__fun<std::__minus, typename _Dom1::value_type>::result_type> std::operator-(const _Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&)' 406 | _DEFINE_EXPR_BINARY_OPERATOR(-, struct std::__minus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__minus, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__minus, typename _Dom1::value_type>::result_type> std::operator-(const typename _Dom::value_type&, const _Expr<_Dom1, typename _Dom1::value_type>&)' 406 | _DEFINE_EXPR_BINARY_OPERATOR(-, struct std::__minus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: template argument deduction/substitution failed: a.cc:16:28: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'char' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__minus, std::_Expr, std::_ValArray, _Dom, typename _Dom::value_type>, typename std::__fun<std::__minus, typename _Dom1::value_type>::result_type> std::operator-(const _Expr<_Dom1, typename _Dom1::value_type>&, const valarray<typename _Dom::value_type>&)' 406 | _DEFINE_EXPR_BINARY_OPERATOR(-, struct std::__minus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__minus, std::_ValArray, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__minus, typename _Dom1::value_type>::result_type> std::operator-(const valarray<typename _Dom::value_type>&, const _Expr<_Dom1, typename _Dom1::value_type>&)' 406 | _DEFINE_EXPR_BINARY_OPERATOR(-, struct std::__minus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/bits/valarray_after.h:406:5: note: template argument deduction/substitution failed: a.cc:16:28: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'char' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/valarray:1197:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__minus, std::_ValArray, std::_ValArray, _Tp, _Tp>, typename std::__fun<std::__minus, _Tp>::result_type> std::operator-(const valarray<_Tp>&, const valarray<_Tp>&)' 1197 | _DEFINE_BINARY_OPERATOR(-, __minus) | ^~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/valarray:1197:1: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::valarray<_Tp>' 16 | cout << "A" << char(s[1]-'a'+'A') << "C" << endl; | ^~~ /usr/include/c++/14/valarray:1197:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__minus, std::_ValArray, std::_Constant, _Tp, _Tp>, typename std::__fun<std::__minus, _Tp>::result_type> std::operator-(const valarray<_Tp>&, const typename valarray<_Tp>::value_type&)' 1197 | _DEFINE_BINARY_OPERATOR(-, __minus) | ^~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/valarray:1197:1: note: template argument deduction/substitution failed: a.cc:16:28: note: '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_
s437535745
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; cin>>S; cout<'A'+S.at(0)+'C'<<endl; }
a.cc: In function 'int main()': a.cc:8:23: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<' 8 | cout<'A'+S.at(0)+'C'<<endl; | ~~~~~~~~~~~~~~~^~~~~~
s298170610
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; S="A"+S.at(8)+"C"; cout<<S<<endl; }
a.cc: In function 'int main()': a.cc:7:16: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | S="A"+S.at(8)+"C"; | ~~~~~~~~~~~^~~~ | | | | | const char [2] | const char*
s280477793
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; cout<<"A"+S.at(8)+"C"<<endl; }
a.cc: In function 'int main()': a.cc:7:20: error: invalid operands of types 'const char*' and 'const char [2]' to binary 'operator+' 7 | cout<<"A"+S.at(8)+"C"<<endl; | ~~~~~~~~~~~^~~~ | | | | | const char [2] | const char*
s073699392
p03860
C++
#include <bits/stdc++.h> using namespace std; int main() { string S; cin >> S; S='A'+S.at(8)+'C' cout<<S<<endl; }
a.cc: In function 'int main()': a.cc:7:20: error: expected ';' before 'cout' 7 | S='A'+S.at(8)+'C' | ^ | ; 8 | cout<<S<<endl; | ~~~~
s378002243
p03860
C++
#include <bits/stdc++.h> using namespace std; int main(){ string "AtCoder",a,"Contest"; cin >> "AtCoder",a,"Contest"; cout << "A" << a.at(0) << "C" << endl; }
a.cc: In function 'int main()': a.cc:6:10: error: expected unqualified-id before string constant 6 | string "AtCoder",a,"Contest"; | ^~~~~~~~~ a.cc:7:7: error: no match for 'operator>>' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'const char [8]') 7 | cin >> "AtCoder",a,"Contest"; | ~~~ ^~ ~~~~~~~~~ | | | | | const char [8] | std::istream {aka std::basic_istream<char>} In file included from /usr/include/c++/14/sstream:40, from /usr/include/c++/14/complex:45, from /usr/include/c++/14/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127, from a.cc:1: /usr/include/c++/14/istream:170:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(bool&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 170 | operator>>(bool& __n) | ^~~~~~~~ /usr/include/c++/14/istream:170:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: cannot bind non-const lvalue reference of type 'bool&' to a value of type 'const char*' 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ /usr/include/c++/14/istream:174:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(short int&) [with _CharT = char; _Traits = std::char_traits<char>]' (near match) 174 | operator>>(short& __n); | ^~~~~~~~ /usr/include/c++/14/istream:174:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'short int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(short int)((const char*)"AtCoder")' to 'short int&' /usr/include/c++/14/istream:177:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(short unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 177 | operator>>(unsigned short& __n) | ^~~~~~~~ /usr/include/c++/14/istream:177:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'short unsigned int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(short unsigned int)((const char*)"AtCoder")' to 'short unsigned int&' /usr/include/c++/14/istream:181:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(int&) [with _CharT = char; _Traits = std::char_traits<char>]' (near match) 181 | operator>>(int& __n); | ^~~~~~~~ /usr/include/c++/14/istream:181:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(int)((const char*)"AtCoder")' to 'int&' /usr/include/c++/14/istream:184:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 184 | operator>>(unsigned int& __n) | ^~~~~~~~ /usr/include/c++/14/istream:184:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'unsigned int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(unsigned int)((const char*)"AtCoder")' to 'unsigned int&' /usr/include/c++/14/istream:188:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 188 | operator>>(long& __n) | ^~~~~~~~ /usr/include/c++/14/istream:188:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'long int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(long int)((const char*)"AtCoder")' to 'long int&' /usr/include/c++/14/istream:192:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 192 | operator>>(unsigned long& __n) | ^~~~~~~~ /usr/include/c++/14/istream:192:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'long unsigned int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(long unsigned int)((const char*)"AtCoder")' to 'long unsigned int&' /usr/include/c++/14/istream:199:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long long int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 199 | operator>>(long long& __n) | ^~~~~~~~ /usr/include/c++/14/istream:199:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'long long int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(long long int)((const char*)"AtCoder")' to 'long long int&' /usr/include/c++/14/istream:203:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long long unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 203 | operator>>(unsigned long long& __n) | ^~~~~~~~ /usr/include/c++/14/istream:203:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const char*' to 'long long unsigned int' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const char* a.cc:7:10: error: cannot bind rvalue '(long long unsigned int)((const char*)"AtCoder")' to 'long long unsigned int&' /usr/include/c++/14/istream:328:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(void*&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' (near match) 328 | operator>>(void*& __p) | ^~~~~~~~ /usr/include/c++/14/istream:328:7: note: conversion of argument 1 would be ill-formed: a.cc:7:10: error: invalid conversion from 'const void*' to 'void*' [-fpermissive] 7 | cin >> "AtCoder",a,"Contest"; | ^~~~~~~~~ | | | const void* a.cc:7:10: error: cannot bind rvalue '(void*)((const void*)((const char*)"AtCoder"))' to 'void*&' /usr/include/c++/14/istream:219:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(float&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' 219 | operator>>(float& __f) | ^~~~~~~~ /usr/include/c++/14/istream:219:25: note: no known conversion for argument 1 from 'const char [8]' to 'float&' 219 | operator>>(float& __f) | ~~~~~~~^~~ /usr/include/c++/14/istream:223:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(double&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' 223 | operator>>(double& __f) | ^~~~~~~~ /usr/include/c++/14/istream:223:26: note: no known conversion for argument 1 from 'const char [8]' to 'double&' 223 | operator>>(double& __f) | ~~~~~~~~^~~ /usr/include/c++/14/istream:227:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long double&) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' 227 | operator>>(long double& __f) | ^~~~~~~~ /usr/include/c++/14/istream:227:31: note: no known conversion for argument 1 from 'const char [8]' to 'long double&' 227 | operator>>(long double& __f) | ~~~~~~~~~~~~~^~~ /usr/include/c++/14/istream:122:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(__istream_type& (*)(__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __istream_type = std::basic_istream<char>]' 122 | operator>>(__istream_type& (*__pf)(__istream_type&)) | ^~~~~~~~ /usr/include/c++/14/istream:122:36: note: no known conversion for argument 1 from 'const char [8]' to 'std::basic_istream<char>::__istream_type& (*)(std::basic_istream<char>::__istream_type&)' {aka 'std::basic_istream<char>& (*)(std::basic_istream<char>&)'} 122 | operator>>(__istream_type& (*__pf)(__istream_type&)) | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/14/istream:126:7: note: candidate: 'std::basic_is
s177276566
p03860
C++
#include<bits/stdc++.h> using namespace std; int main(){ string AtCoder, Contest; string s; cin >> AtCoder >> s >> Contest; cout << Atcoder.at(0) << s.at(0) << Contest.at(0) << endl; }
a.cc: In function 'int main()': a.cc:9:11: error: 'Atcoder' was not declared in this scope; did you mean 'AtCoder'? 9 | cout << Atcoder.at(0) << s.at(0) << Contest.at(0) << endl; | ^~~~~~~ | AtCoder