submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s899922005 | p03636 | C++ | #include<iostream>
#include<bits/stdc++.h>
using namespace std;
char s[100000];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(S)-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
7 | gets(s);
| ^~~~
| getw
a.cc:8:39: error: 'S' was not declared in this scope
8 | cout<<s[0]<<strlen(s)-2<<s[strlen(S)-1];
| ^
|
s511119959 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin >> s;
int l=s.size()-2;
cout>>s[0]>>l>>s[s.size()-1];
} | a.cc: In function 'int main()':
a.cc:7:7: 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'})
7 | cout>>s[0]>>l>>s[s.size()-1];
a.cc:7:7: note: candidate: 'operator>>(int, int)' (built-in)
a.cc:7:7: 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:7:3: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^~~~
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: required from here
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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 argument deduction/substitution failed:
a.cc:7:12: note: 'std::ostream' {aka |
s324918209 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin >> s;
l=s.size()-2;
cout>>s[0]>>l>>s[s.size()-1];
} | a.cc: In function 'int main()':
a.cc:6:3: error: 'l' was not declared in this scope
6 | l=s.size()-2;
| ^
a.cc:7:7: 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'})
7 | cout>>s[0]>>l>>s[s.size()-1];
a.cc:7:7: note: candidate: 'operator>>(int, int)' (built-in)
a.cc:7:7: 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:7:3: note: cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^~~~
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: required from here
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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:7:12: note: 'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
7 | cout>>s[0]>>l>>s[s.size()-1];
| ^
/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: |
s554024055 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char s[1000];
int main()
{
cin>>s;
cout<<s[0]<<strlen(s)-1<<s[len-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:7:32: error: 'len' was not declared in this scope
7 | cout<<s[0]<<strlen(s)-1<<s[len-1];
| ^~~
|
s611462810 | p03636 | C++ | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
int main () {
string s; cin >> s;
char start = s[0], end = s[s.size() = 1];
printf("%c%d%c", start, s.size() - 2, end);
return 0;
} | a.cc: In function 'int main()':
a.cc:7:38: error: lvalue required as left operand of assignment
7 | char start = s[0], end = s[s.size() = 1];
| ~~~~~~^~
|
s111221580 | p03636 | C++ | #include<bits/stdc++.h>
string s;
int main()
{
cin>>s;
cout<<s[0]<<s.size()-2<<s[s.size()-1];
return 0;
}
| a.cc:2:1: error: 'string' does not name a type; did you mean 'stdin'?
2 | string s;
| ^~~~~~
| stdin
a.cc: In function 'int main()':
a.cc:5:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
5 | cin>>s;
| ^~~
| std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
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:5:10: error: 's' was not declared in this scope
5 | cin>>s;
| ^
a.cc:6:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
6 | cout<<s[0]<<s.size()-2<<s[s.size()-1];
| ^~~~
| std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
63 | extern ostream cout; ///< Linked to standard output
| ^~~~
|
s608201405 | p03636 | C++ | #include<string>
#include<iostream>
using namespace std;
int main()
{
string str;
cin>>str;
cout<<str[0]<<str.length()-2<<str[sr.length()-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:8:39: error: 'sr' was not declared in this scope; did you mean 'str'?
8 | cout<<str[0]<<str.length()-2<<str[sr.length()-1]<<endl;
| ^~
| str
|
s862659157 | p03636 | C++ | #include<iostream>
#include<algorithm>
#include<cstdio>
#include<fstream>
#include<cstdlib>
#include<iomanip>
#include<string>
#include<cstring>
#include<cmath>
#include<cfloat>
using namespace std;
int main()
{
string s;
cin>>s;
cout<<s[0]<<s.size()-2<<a[s.size()-1];
exit(0);
} | a.cc: In function 'int main()':
a.cc:17:29: error: 'a' was not declared in this scope
17 | cout<<s[0]<<s.size()-2<<a[s.size()-1];
| ^
|
s572069305 | p03636 | C++ | #include<iostream>
#include<cstdio>
#include<cmath>
#include<algorithm>
#include<string>
#include<cstring>
using namespace std;
string a;
int main()
{
cin>>a;
cout<<a[0]<<a.size()-2<<a[s.size()-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:13:35: error: 's' was not declared in this scope
13 | cout<<a[0]<<a.size()-2<<a[s.size()-1];
| ^
|
s802185841 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char s[10000];//定义
int main()
{
gets(s);//输入
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];//输出
return 0;//完美结束
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);//输入
| ^~~~
| getw
|
s561561921 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char str[110];
int main() {
scanf("%s", str + 1);
int len = strlen(str + 1);
printf("%c%d%c\n", str[1], len - 2, str[n]);
return 0;
} | a.cc: In function 'int main()':
a.cc:9:49: error: 'n' was not declared in this scope; did you mean 'yn'?
9 | printf("%c%d%c\n", str[1], len - 2, str[n]);
| ^
| yn
|
s737156612 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char str[110];
int main() {
gets(str + 1);
int len = strlen(str + 1);
printf("%c%d%c\n", str[1], len - 2, str[n]);
return 0;
} | a.cc: In function 'int main()':
a.cc:7:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
7 | gets(str + 1);
| ^~~~
| getw
a.cc:9:49: error: 'n' was not declared in this scope; did you mean 'yn'?
9 | printf("%c%d%c\n", str[1], len - 2, str[n]);
| ^
| yn
|
s302725810 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char str[110];
int main() {
gets(str + 1);
int len = strlen(str + 1);
printf("%c%d%c\n", str[1], len, str[n]);
return 0;
} | a.cc: In function 'int main()':
a.cc:7:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
7 | gets(str + 1);
| ^~~~
| getw
a.cc:9:45: error: 'n' was not declared in this scope; did you mean 'yn'?
9 | printf("%c%d%c\n", str[1], len, str[n]);
| ^
| yn
|
s342016103 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
string xxx[10020];
int main()
{
gets(s);
int y=strlen(s)-2;
cout<<xxx[0]<<y<<xxx[y+1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:10: error: 's' was not declared in this scope
6 | gets(s);
| ^
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
|
s359273594 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char xxx[10020];
int main()
{
gets(s);
int y=strlen(s)-2;
cout<<xxx[0]<<y<<xxx[y+1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:10: error: 's' was not declared in this scope
6 | gets(s);
| ^
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
|
s736932935 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char xxx[10020];
int main()
{
gets(s);
int y=strlen(s)-2;
cout<<xxx[0]<<s<<xxx[y+1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:10: error: 's' was not declared in this scope
6 | gets(s);
| ^
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
|
s924458799 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int mian(){
string a;
cin>>a;
cout<<a[0]<<a.length()-2<<a[a.length()-1];
} | a.cc: In function 'int mian()':
a.cc:7:1: warning: no return statement in function returning non-void [-Wreturn-type]
7 | }
| ^
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
|
s302822238 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
char s[1234];
cin<<s;
int len=strlen(s);
cout<<s[0]<<len-2<<s[len-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:5:8: error: no match for 'operator<<' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'char [1234]')
5 | cin<<s;
| ~~~^~~
| | |
| | char [1234]
| std::istream {aka std::basic_istream<char>}
In file included from /usr/include/c++/14/regex:68,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:181,
from a.cc:1:
/usr/include/c++/14/bits/regex.h:1715:5: note: candidate: 'template<class _Ch_type, class _Ch_traits, class _Bi_iter> std::basic_ostream<_CharT, _Traits>& std::__cxx11::operator<<(std::basic_ostream<_CharT, _Traits>&, const sub_match<_Bi_iter>&)'
1715 | operator<<(basic_ostream<_Ch_type, _Ch_traits>& __os,
| ^~~~~~~~
/usr/include/c++/14/bits/regex.h:1715:5: note: template argument deduction/substitution failed:
a.cc:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:41:
/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:5:5: note: cannot convert 'std::cin' (type 'std::istream' {aka 'std::basic_istream<char>'}) to type 'std::byte'
5 | cin<<s;
| ^~~
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/bitset:52,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52:
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
/usr/include/c++/14/bitset:1687:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const bitset<_Nb>&)'
1687 | operator<<(std::basic_ostream<_CharT, _Traits>& __os,
| ^~~~~~~~
/usr/include/c++/14/bitset:1687:5: note: template argument deduction/substitution failed:
a.cc:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
In file included from /usr/include/c++/14/bits/ios_base.h:46,
from /usr/include/c++/14/streambuf:43,
from /usr/include/c++/14/bits/streambuf_iterator.h:35,
from /usr/include/c++/14/iterator:66,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:54:
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
In file included from /usr/include/c++/14/memory:80,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:56:
/usr/include/c++/14/bits/shared_ptr.h:70:5: note: candidate: 'template<class _Ch, class _Tr, class _Tp, __gnu_cxx::_Lock_policy _Lp> std::basic_ostream<_CharT, _Traits>& std::operator<<(basic_ostream<_CharT, _Traits>&, const __shared_ptr<_Tp, _Lp>&)'
70 | operator<<(std::basic_ostream<_Ch, _Tr>& __os,
| ^~~~~~~~
/usr/include/c++/14/bits/shared_ptr.h:70:5: note: template argument deduction/substitution failed:
a.cc:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
In file included from /usr/include/c++/14/istream:41,
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/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<_CharT, _Traits>'
5 | cin<<s;
| ^
/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:5:10: note: 'std::istream' {aka 'std::basic_istream<char>'} is not derived from 'std::basic_ostream<char, _Traits>'
5 | cin<<s;
| ^
/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 |
s669163104 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
string s;
cin>>s;
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
return 0;
}
| a.cc: In function 'int main()':
a.cc:8:28: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
8 | cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/14/cstring:43,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
from a.cc:1:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
a.cc:8:43: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
8 | cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
|
s002900144 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
string s;
cin>>s;
cout<<s[0]<<strlen(s)-2<<s%10;
return 0;
}
| a.cc: In function 'int main()':
a.cc:8:28: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/14/cstring:43,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
from a.cc:1:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
a.cc:8:35: error: no match for 'operator%' (operand types are 'std::string' {aka 'std::__cxx11::basic_string<char>'} and 'int')
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ~^~~
| | |
| | int
| std::string {aka std::__cxx11::basic_string<char>}
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:409:5: note: candidate: 'template<class _Dom1, class _Dom2> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Expr, _Dom1, _Dom2>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const _Expr<_Dom2, typename _Dom2::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:8:36: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:8:36: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const typename _Dom::value_type&, const _Expr<_Dom1, typename _Dom1::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:8:36: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'int'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_ValArray, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const valarray<typename _Dom::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:8:36: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const valarray<typename _Dom::value_type>&, const _Expr<_Dom1, typename _Dom1::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:8:36: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'int'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_ValArray, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const valarray<_Tp>&, const valarray<_Tp>&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:8:36: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::valarray<_Tp>'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_Constant, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const valarray<_Tp>&, const typename valarray<_Tp>::value_type&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:8:36: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::valarray<_Tp>'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Constant, std::_ValArray, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const typename valarray<_Tp>::value_type&, const valarray<_Tp>&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:8:36: note: mismatched types 'const std::valarray<_Tp>' and 'int'
8 | cout<<s[0]<<strlen(s)-2<<s%10;
| ^~
|
s262300315 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
string s;
int i,n,a;
cin>>s;
a=strlen(s)-2;
n=s%10;
i=s[0];
cout<<ian;
return 0;
}
| a.cc: In function 'int main()':
a.cc:9:18: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
9 | a=strlen(s)-2;
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/14/cstring:43,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
from a.cc:1:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
a.cc:10:12: error: no match for 'operator%' (operand types are 'std::string' {aka 'std::__cxx11::basic_string<char>'} and 'int')
10 | n=s%10;
| ~^~~
| | |
| | int
| std::string {aka std::__cxx11::basic_string<char>}
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:409:5: note: candidate: 'template<class _Dom1, class _Dom2> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Expr, _Dom1, _Dom2>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const _Expr<_Dom2, typename _Dom2::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:10:13: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
10 | n=s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:10:13: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
10 | n=s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const typename _Dom::value_type&, const _Expr<_Dom1, typename _Dom1::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:10:13: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'int'
10 | n=s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_ValArray, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const valarray<typename _Dom::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:10:13: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>'
10 | n=s%10;
| ^~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const valarray<typename _Dom::value_type>&, const _Expr<_Dom1, typename _Dom1::value_type>&)'
409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed:
a.cc:10:13: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'int'
10 | n=s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_ValArray, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const valarray<_Tp>&, const valarray<_Tp>&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:10:13: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::valarray<_Tp>'
10 | n=s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_Constant, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const valarray<_Tp>&, const typename valarray<_Tp>::value_type&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:10:13: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::valarray<_Tp>'
10 | n=s%10;
| ^~
/usr/include/c++/14/valarray:1200:1: note: candidate: 'template<class _Tp> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Constant, std::_ValArray, _Tp, _Tp>, typename std::__fun<std::__modulus, _Tp>::result_type> std::operator%(const typename valarray<_Tp>::value_type&, const valarray<_Tp>&)'
1200 | _DEFINE_BINARY_OPERATOR(%, __modulus)
| ^~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/valarray:1200:1: note: template argument deduction/substitution failed:
a.cc:10:13: note: mismatched types 'const std::valarray<_Tp>' and 'int'
10 | n=s%10;
| ^~
a.cc:12:15: error: 'ian' was not declared in this scope; did you mean 'tan'?
12 | cout<<ian;
| ^~~
| tan
|
s169198562 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
char s;
int n=0;
int l=strlen(s);
for(int i=2;i<=l-1;i++){
n++;
}
cout<<s[0]<<n<<s[l]<<endl;
} | a.cc: In function 'int main()':
a.cc:7:18: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
7 | int l=strlen(s);
| ^
| |
| char
In file included from /usr/include/c++/14/cstring:43,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
from a.cc:1:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
a.cc:11:12: error: invalid types 'char[int]' for array subscript
11 | cout<<s[0]<<n<<s[l]<<endl;
| ^
a.cc:11:21: error: invalid types 'char[int]' for array subscript
11 | cout<<s[0]<<n<<s[l]<<endl;
| ^
|
s616964718 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char s[10000];
int main()
{
gets(s);
printf("%c%d%c",s[0],strlen(s)-2,s[strlen(s)-1]);
return 0;
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
a.cc:7:12: error: unable to find string literal operator 'operator""\U0000ff0cs' with 'const char [7]', 'long unsigned int' arguments
7 | printf("%c%d%c",s[0],strlen(s)-2,s[strlen(s)-1]);
| ^~~~~~~~~~~
|
s557077019 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main (){
string s;
cin >> s;
int A = s.length();
B = A - 2;
cout << s[0] + B + S[A - 1];
} | a.cc: In function 'int main()':
a.cc:12:3: error: 'B' was not declared in this scope
12 | B = A - 2;
| ^
a.cc:14:22: error: 'S' was not declared in this scope
14 | cout << s[0] + B + S[A - 1];
| ^
|
s115581987 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double lf;
#define reg register
#define gc() (p1==p2&&(p2=(p1=buf)+fread(buf,1,1<<21,stdin),p1==p2)?EOF:*p1++)
#define input(a){a=0;char c=gc();int f=1;while(c<'0'||c>'9'){if(c=='-')f=-1;c=gc();}while(c>='0'&&c<='9'){a=(a<<3)+(a<<1)+(c&15);c=gc();}a*=f;}
static char buf[1<<21],*p1=buf,*p2=buf;
char bu[1<<21],cha[20];int p,pp=-1;
#define flush(){fwrite(bu,1,pp+1,stdout),pp=-1;}
#define output(x){if(pp>1<<20)flush();if(x<0)bu[++pp]=45,x=-x;do{cha[++p]=x%10+48;}while(x/=10);do{bu[++pp]=cha[p];}while(--p);}
#define Endl bu[++pp]='\n'
#define Space bu[++pp]=' '
#define pc(c) bu[++pp]=c
const int N=110;
char s[N];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
flush();
return 0;
} | a.cc: In function 'int main()':
a.cc:19:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
19 | gets(s);
| ^~~~
| getw
|
s950101124 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std
int main()
{
int len;
char a[1001];
cin>>a;
len=strlen(a)-2;
cout<<a[0]<<len<<a[strlen(a)-1]<<endl;
return 0;
} | a.cc:2:20: error: expected ';' before 'int'
2 | using namespace std
| ^
| ;
3 | int main()
| ~~~
|
s159787881 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
cout << a.at(0) << s.size() - 2 << s.at(s.size() - 1) << endl;
} | a.cc: In function 'int main()':
a.cc:6:11: error: 'a' was not declared in this scope
6 | cout << a.at(0) << s.size() - 2 << s.at(s.size() - 1) << endl;
| ^
|
s825289287 | p03636 | C++ | #include<iostream>
#include<cstdio>
#include<cstring>
int main(){
string s;
std::cin>>s;
std::cout<<s[0]<<s.size()-2<<s[s.size()-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:5:5: error: 'string' was not declared in this scope
5 | string s;
| ^~~~~~
a.cc:5:5: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
from /usr/include/c++/14/ios:40,
from /usr/include/c++/14/ostream:40,
from /usr/include/c++/14/iostream:41,
from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note: 'std::string'
77 | typedef basic_string<char> string;
| ^~~~~~
In file included 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:
/usr/include/c++/14/string:76:11: note: 'std::pmr::string'
76 | using string = basic_string<char>;
| ^~~~~~
a.cc:6:15: error: 's' was not declared in this scope
6 | std::cin>>s;
| ^
|
s877766525 | p03636 | C++ | #include<iostream>
int main(){
string s;
std::cin>>s;
std::cout<<s[0]<<s.size()-2<<s[s.size()-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:3:5: error: 'string' was not declared in this scope
3 | string s;
| ^~~~~~
a.cc:3:5: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
from /usr/include/c++/14/ios:40,
from /usr/include/c++/14/ostream:40,
from /usr/include/c++/14/iostream:41,
from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note: 'std::string'
77 | typedef basic_string<char> string;
| ^~~~~~
In file included 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:
/usr/include/c++/14/string:76:11: note: 'std::pmr::string'
76 | using string = basic_string<char>;
| ^~~~~~
a.cc:4:15: error: 's' was not declared in this scope
4 | std::cin>>s;
| ^
|
s713937783 | p03636 | C++ | // luogu-judger-enable-o2
#include <bits/stdc++.h>
using namespace std;
int main(){
char a[105]=;
scanf("%s",a);
printf("%c%d%c",a[0],strlen(a),a[strlen(a)-1]);
return 0;
} | a.cc: In function 'int main()':
a.cc:5:17: error: expected primary-expression before ';' token
5 | char a[105]=;
| ^
|
s033708435 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
char a[100000];
gets(a);
int n = 0;
int len = strlen(a);
for (int i = 1; i < len-1; i++)
{
n ++;
}
printf("%c%d%c\n", a[0], n, a[len-1]);
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(a);
| ^~~~
| getw
|
s176440723 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
char a[100000];
gets(a);
int n = 0;
int len = strlen(a);
for (int i = 1; i < len-1; i++)
{
n ++;
}
printf("%c%d%c\n", a[0], n, a[len-1]);
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(a);
| ^~~~
| getw
|
s443617795 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main(){
string S;
cin >> S;
cout<<S[0]<<S.size()-2<<S[-1];<<endl;
} | a.cc: In function 'int main()':
a.cc:9:33: error: expected primary-expression before '<<' token
9 | cout<<S[0]<<S.size()-2<<S[-1];<<endl;
| ^~
|
s656839121 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main(){
string S;
cin >> S;
string ans =S[0]+string(S.size()-2)+S[-1];
cout<<ans<<endl;
} | a.cc: In function 'int main()':
a.cc:8:37: error: no matching function for call to 'std::__cxx11::basic_string<char>::basic_string(std::__cxx11::basic_string<char>::size_type)'
8 | string ans =S[0]+string(S.size()-2)+S[-1];
| ^
In file included 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/bits/basic_string.h:800:9: note: candidate: 'template<class _Tp, class> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _Tp&, const _Alloc&) [with <template-parameter-2-2> = _Tp; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
800 | basic_string(const _Tp& __t, const _Alloc& __a = _Alloc())
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:800:9: note: template argument deduction/substitution failed:
In file included from /usr/include/c++/14/bits/move.h:37,
from /usr/include/c++/14/bits/exception_ptr.h:41,
from /usr/include/c++/14/exception:166,
from /usr/include/c++/14/ios:41:
/usr/include/c++/14/type_traits: In substitution of 'template<bool _Cond, class _Tp> using std::enable_if_t = typename std::enable_if::type [with bool _Cond = false; _Tp = void]':
/usr/include/c++/14/bits/basic_string.h:149:8: required by substitution of 'template<class _CharT, class _Traits, class _Alloc> template<class _Tp, class _Res> using std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_If_sv = std::enable_if_t<((bool)std::__and_<std::is_convertible<const _Tp&, std::basic_string_view<_CharT, _Traits> >, std::__not_<std::is_convertible<const _Tp*, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>*> >, std::__not_<std::is_convertible<const _Tp&, const _CharT*> > >::value), _Res> [with _Tp = long unsigned int; _Res = void; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
149 | using _If_sv = enable_if_t<
| ^~~~~~
/usr/include/c++/14/bits/basic_string.h:797:30: required from here
797 | template<typename _Tp, typename = _If_sv<_Tp, void>>
| ^~~~~~~~
/usr/include/c++/14/type_traits:2711:11: error: no type named 'type' in 'struct std::enable_if<false, void>'
2711 | using enable_if_t = typename enable_if<_Cond, _Tp>::type;
| ^~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:788:9: note: candidate: 'template<class _Tp, class> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _Tp&, size_type, size_type, const _Alloc&) [with <template-parameter-2-2> = _Tp; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
788 | basic_string(const _Tp& __t, size_type __pos, size_type __n,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:788:9: note: candidate expects 3 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:765:9: note: candidate: 'template<class _InputIterator, class> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(_InputIterator, _InputIterator, const _Alloc&) [with <template-parameter-2-2> = _InputIterator; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
765 | basic_string(_InputIterator __beg, _InputIterator __end,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:765:9: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:669:7: note: candidate: 'template<class> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(size_type, _CharT, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
669 | basic_string(size_type __n, _CharT __c, const _Alloc& __a = _Alloc())
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:669:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:646:7: note: candidate: 'template<class> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
646 | basic_string(const _CharT* __s, const _Alloc& __a = _Alloc())
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:646:7: note: template argument deduction/substitution failed:
a.cc:8:35: note: cannot convert '(S.std::__cxx11::basic_string<char>::size() - 2)' (type 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'}) to type 'const char*'
8 | string ans =S[0]+string(S.size()-2)+S[-1];
| ~~~~~~~~^~
/usr/include/c++/14/bits/basic_string.h:721:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
721 | basic_string(basic_string&& __str, const _Alloc& __a)
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:721:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:716:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
716 | basic_string(const basic_string& __str, const _Alloc& __a)
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:716:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:711:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::initializer_list<_Tp>, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
711 | basic_string(initializer_list<_CharT> __l, const _Alloc& __a = _Alloc())
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:711:45: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} to 'std::initializer_list<char>'
711 | basic_string(initializer_list<_CharT> __l, const _Alloc& __a = _Alloc())
| ~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/basic_string.h:682:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
682 | basic_string(basic_string&& __str) noexcept
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:682:35: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} to 'std::__cxx11::basic_string<char>&&'
682 | basic_string(basic_string&& __str) noexcept
| ~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/14/bits/basic_string.h:624:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, size_type, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
624 | basic_string(const _CharT* __s, size_type __n,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:624:7: note: candidate expects 3 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:604:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, size_type, size_type, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
604 | basic_string(const basic_string& __str, size_type __pos,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:604:7: note: candidate expects 4 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:586:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, size_type, size_type) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
586 | basic_string(const basic_string& __str, size_type __pos,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:586:7: note: candidate expects 3 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:569:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, size_type, const _Alloc&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
569 | basic_string(const basic_string& __str, size_type __pos,
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:569:7: note: candidate expects 3 arguments, 1 provided
/usr/include/c++/14/bits/basic_string.h:552:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]'
552 | basic_string(const basic_string& __str)
| ^~~~~~~~~~~~
/usr/include/c++/14/bits/basic_string.h:552:40: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} to 'const std::__cxx11::basic_string<char>&'
552 | basic_string(const basic_string& __str)
| ~~~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/14/bits/basic_string.h:540:7: note: candidate: 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const |
s795770500 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main(){
string S;
cin >> S;
string ans =S[0]+(S.size()-2)+S[-1];
cout<<ans<<endl;
} | a.cc: In function 'int main()':
a.cc:8:32: error: conversion from 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
8 | string ans =S[0]+(S.size()-2)+S[-1];
|
s546407070 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char a[10001];
int c;
int main()
{
scanf("%s",&a);
c=strlen(a);
printf("%c%d%c\n",s[0],c-2,s[c-1]);
return 0;
} | a.cc: In function 'int main()':
a.cc:9:23: error: 's' was not declared in this scope
9 | printf("%c%d%c\n",s[0],c-2,s[c-1]);
| ^
|
s796158354 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int INF = 1e9;
//long long
using ll = long long;
//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
// begin() end()
#define all(x) (x).begin(),(x).end()
//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
//最大公約数
ll gcd(ll a,ll b){
if(b == 0) return a;
return gcd(b,a%b);
}
//最小公倍数
ll lcm(ll a,ll b){
ll g = gcd(a,b);
return a / g * b; // Be careful not to overflow if(a < b) return gcd(b, a);
unsigned r;
while ((r=a%b)) {
a = b;
b = r;
}
return b;
}
int main(){
string s;
cin >> s;
int cnt = s.length() - 2;
cout << s.at(0) << cnt << s.at(s.length - 1) << endl;
} | a.cc: In function 'int main()':
a.cc:48:34: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::length() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
48 | cout << s.at(0) << cnt << s.at(s.length - 1) << endl;
| ~~^~~~~~
| ()
|
s199474950 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int INF = 1e9;
//long long
using ll = long long;
//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
// begin() end()
#define all(x) (x).begin(),(x).end()
//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
//最大公約数
ll gcd(ll a,ll b){
if(b == 0) return a;
return gcd(b,a%b);
}
//最小公倍数
ll lcm(ll a,ll b){
ll g = gcd(a,b);
return a / g * b; // Be careful not to overflow if(a < b) return gcd(b, a);
unsigned r;
while ((r=a%b)) {
a = b;
b = r;
}
return b;
}
int main(){
string s;
cin >> s;
int cnt = s.length() - 2;
cout << s.at(0) << cnt << s.at(S.length - 1) << endl;
} | a.cc: In function 'int main()':
a.cc:48:32: error: 'S' was not declared in this scope
48 | cout << s.at(0) << cnt << s.at(S.length - 1) << endl;
| ^
|
s830922992 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int INF = 1e9;
//long long
using ll = long long;
//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
// begin() end()
#define all(x) (x).begin(),(x).end()
//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
//最大公約数
ll gcd(ll a,ll b){
if(b == 0) return a;
return gcd(b,a%b);
}
//最小公倍数
ll lcm(ll a,ll b){
ll g = gcd(a,b);
return a / g * b; // Be careful not to overflow if(a < b) return gcd(b, a);
unsigned r;
while ((r=a%b)) {
a = b;
b = r;
}
return b;
}
int main(){
string s;
cin >> s;
int cnt = S.length() - 2;
cout << s.at(0) << cnt << s.at(S.length - 1) << endl;
} | a.cc: In function 'int main()':
a.cc:47:11: error: 'S' was not declared in this scope
47 | int cnt = S.length() - 2;
| ^
|
s604480433 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int INF = 1e9;
//long long
using ll = long long;
//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
// begin() end()
#define all(x) (x).begin(),(x).end()
//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
//最大公約数
ll gcd(ll a,ll b){
if(b == 0) return a;
return gcd(b,a%b);
}
//最小公倍数
ll lcm(ll a,ll b){
ll g = gcd(a,b);
return a / g * b; // Be careful not to overflow if(a < b) return gcd(b, a);
unsigned r;
while ((r=a%b)) {
a = b;
b = r;
}
return b;
}
int main(){
string s;
cin >> s;
int cnt = S.length() - 2;
cout << x.at(0) << cnt << x.at(S.length - 1) << endl;
} | a.cc: In function 'int main()':
a.cc:47:11: error: 'S' was not declared in this scope
47 | int cnt = S.length() - 2;
| ^
a.cc:48:9: error: 'x' was not declared in this scope
48 | cout << x.at(0) << cnt << x.at(S.length - 1) << endl;
| ^
|
s931082929 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int INF = 1e9;
//long long
using ll = long long;
//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
// begin() end()
#define all(x) (x).begin(),(x).end()
//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
//最大公約数
ll gcd(ll a,ll b){
if(b == 0) return a;
return gcd(b,a%b);
}
//最小公倍数
ll lcm(ll a,ll b){
ll g = gcd(a,b);
return a / g * b; // Be careful not to overflow if(a < b) return gcd(b, a);
unsigned r;
while ((r=a%b)) {
a = b;
b = r;
}
return b;
}
string s;
cin >> s;
int cnt = S.length() - 2;
cout << x.at(0) << cnt << x.at(S.length - 1) << endl;
} | a.cc:44:1: error: 'cin' does not name a type
44 | cin >> s;
| ^~~
a.cc:46:11: error: 'S' was not declared in this scope
46 | int cnt = S.length() - 2;
| ^
a.cc:47:1: error: 'cout' does not name a type
47 | cout << x.at(0) << cnt << x.at(S.length - 1) << endl;
| ^~~~
a.cc:49:1: error: expected declaration before '}' token
49 | }
| ^
|
s965504679 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin>>s;
cout<<s[0]<<s.length()-2<<s[(int)s.length()-1]<<endl; | a.cc: In function 'int main()':
a.cc:7:56: error: expected '}' at end of input
7 | cout<<s[0]<<s.length()-2<<s[(int)s.length()-1]<<endl;
| ^
a.cc:4:11: note: to match this '{'
4 | int main(){
| ^
|
s714143380 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin>>s;
cout<<s[0]<<s.length()-2<<s[n-1]<<endl; | a.cc: In function 'int main()':
a.cc:7:31: error: 'n' was not declared in this scope
7 | cout<<s[0]<<s.length()-2<<s[n-1]<<endl;
| ^
a.cc:7:42: error: expected '}' at end of input
7 | cout<<s[0]<<s.length()-2<<s[n-1]<<endl;
| ^
a.cc:4:11: note: to match this '{'
4 | int main(){
| ^
|
s872992498 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main(){
string s
int len;
cin>>s;
len=s.length();
cout<<s[0]<<len-2<<s[len-1];
} | a.cc: In function 'int main()':
a.cc:6:1: error: expected initializer before 'int'
6 | int len;
| ^~~
a.cc:7:6: error: 's' was not declared in this scope
7 | cin>>s;
| ^
a.cc:8:1: error: 'len' was not declared in this scope; did you mean 'mblen'?
8 | len=s.length();
| ^~~
| mblen
|
s087555956 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main(){
string s;
cin>>s;
len=s.length();
cout<<s[0]<<len-2<<s[len-1];
} | a.cc: In function 'int main()':
a.cc:7:1: error: 'len' was not declared in this scope; did you mean 'mblen'?
7 | len=s.length();
| ^~~
| mblen
|
s432081167 | p03636 | C++ | #include<iostream>
#include<cstring>
using namespace std;
char ss[1010];
int main()
{
gets(ss);
cout<<ss[0]<<strlen(ss)-2<<ss[strlen(ss)-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:7:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
7 | gets(ss);
| ^~~~
| getw
|
s316525154 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
string t;
cin >> s;
string l;
l = 's.size() - 2';
cout << 's[0]' + l + 's[s.size() - 1]' << endl;
} | a.cc:9:7: warning: multi-character literal with 12 characters exceeds 'int' size of 4 bytes
9 | l = 's.size() - 2';
| ^~~~~~~~~~~~~~
a.cc:10:11: warning: multi-character character constant [-Wmultichar]
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^~~~~~
a.cc:10:24: warning: multi-character literal with 15 characters exceeds 'int' size of 4 bytes
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^~~~~~~~~~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:7: warning: overflow in conversion from 'int' to 'char' changes value from '539828274' to '50' [-Woverflow]
9 | l = 's.size() - 2';
| ^~~~~~~~~~~~~~
a.cc:10:18: error: no match for 'operator+' (operand types are 'int' and 'std::string' {aka 'std::__cxx11::basic_string<char>'})
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ~~~~~~ ^ ~
| | |
| int std::string {aka std::__cxx11::basic_string<char>}
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:627:5: note: candidate: 'template<class _Iterator> constexpr std::reverse_iterator<_Iterator> std::operator+(typename reverse_iterator<_Iterator>::difference_type, const reverse_iterator<_Iterator>&)'
627 | operator+(typename reverse_iterator<_Iterator>::difference_type __n,
| ^~~~~~~~
/usr/include/c++/14/bits/stl_iterator.h:627:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::reverse_iterator<_Iterator>'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/stl_iterator.h:1798:5: note: candidate: 'template<class _Iterator> constexpr std::move_iterator<_IteratorL> std::operator+(typename move_iterator<_IteratorL>::difference_type, const move_iterator<_IteratorL>&)'
1798 | operator+(typename move_iterator<_Iterator>::difference_type __n,
| ^~~~~~~~
/usr/include/c++/14/bits/stl_iterator.h:1798:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: 'std::string' {aka 'std::__cxx11::basic_string<char>'} is not derived from 'const std::move_iterator<_IteratorL>'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
In file included from /usr/include/c++/14/string:54,
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.h:3598:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const __cxx11::basic_string<_CharT, _Traits, _Allocator>&, const __cxx11::basic_string<_CharT, _Traits, _Allocator>&)'
3598 | operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3598:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3616:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const _CharT*, const __cxx11::basic_string<_CharT, _Traits, _Allocator>&)'
3616 | operator+(const _CharT* __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3616:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const _CharT*' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3635:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(_CharT, const __cxx11::basic_string<_CharT, _Traits, _Allocator>&)'
3635 | operator+(_CharT __lhs, const basic_string<_CharT,_Traits,_Alloc>& __rhs)
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3635:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: deduced conflicting types for parameter '_CharT' ('int' and 'char')
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3652:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const __cxx11::basic_string<_CharT, _Traits, _Allocator>&, const _CharT*)'
3652 | operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3652:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3670:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const __cxx11::basic_string<_CharT, _Traits, _Allocator>&, _CharT)'
3670 | operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, _CharT __rhs)
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3670:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3682:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, const __cxx11::basic_string<_CharT, _Traits, _Allocator>&)'
3682 | operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3682:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3689:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const __cxx11::basic_string<_CharT, _Traits, _Allocator>&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&&)'
3689 | operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3689:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3696:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, __cxx11::basic_string<_CharT, _Traits, _Allocator>&&)'
3696 | operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3696:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3719:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(const _CharT*, __cxx11::basic_string<_CharT, _Traits, _Allocator>&&)'
3719 | operator+(const _CharT* __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3719:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'const _CharT*' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3726:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(_CharT, __cxx11::basic_string<_CharT, _Traits, _Allocator>&&)'
3726 | operator+(_CharT __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3726:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: deduced conflicting types for parameter '_CharT' ('int' and 'char')
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3733:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, const _CharT*)'
3733 | operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs,
| ^~~~~~~~
/usr/include/c++/14/bits/basic_string.h:3733:5: note: template argument deduction/substitution failed:
a.cc:10:20: note: mismatched types 'std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'int'
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^
/usr/include/c++/14/bits/basic_string.h:3740:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, _CharT)'
3740 | operator+(basic_string<_CharT, _Traits, _Alloc> |
s998962450 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
string t;
cin >> s;
sting l;
l = 's.size() - 2';
cout << 's[0]' + l + 's[s.size() - 1]' << endl;
} | a.cc:9:7: warning: multi-character literal with 12 characters exceeds 'int' size of 4 bytes
9 | l = 's.size() - 2';
| ^~~~~~~~~~~~~~
a.cc:10:11: warning: multi-character character constant [-Wmultichar]
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^~~~~~
a.cc:10:24: warning: multi-character literal with 15 characters exceeds 'int' size of 4 bytes
10 | cout << 's[0]' + l + 's[s.size() - 1]' << endl;
| ^~~~~~~~~~~~~~~~~
a.cc: In function 'int main()':
a.cc:8:3: error: 'sting' was not declared in this scope
8 | sting l;
| ^~~~~
a.cc:9:3: error: 'l' was not declared in this scope
9 | l = 's.size() - 2';
| ^
|
s417892167 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
string t;
cin >> s;
int l;
l = s.size() - 2;
t = l
cout << 's[0]' + 't' + 's[s.size() - 1]' << endl;
} | a.cc:11:11: warning: multi-character character constant [-Wmultichar]
11 | cout << 's[0]' + 't' + 's[s.size() - 1]' << endl;
| ^~~~~~
a.cc:11:26: warning: multi-character literal with 15 characters exceeds 'int' size of 4 bytes
11 | cout << 's[0]' + 't' + 's[s.size() - 1]' << endl;
| ^~~~~~~~~~~~~~~~~
a.cc: In function 'int main()':
a.cc:10:8: error: expected ';' before 'cout'
10 | t = l
| ^
| ;
11 | cout << 's[0]' + 't' + 's[s.size() - 1]' << endl;
| ~~~~
|
s885031816 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
string t;
cin >> s;
int l;
l = s.size() - 2;
t = l
cout << s[0] + t + s[s.size() - 1] << endl;
} | a.cc: In function 'int main()':
a.cc:10:8: error: expected ';' before 'cout'
10 | t = l
| ^
| ;
11 | cout << s[0] + t + s[s.size() - 1] << endl;
| ~~~~
|
s700742173 | p03636 | C++ | #include<bits/stdc++.h
using namespace std;
int main(){
string a;
cin>>a;
cout<<a[1]<<a.length()<<a[a.length()];
} | a.cc:1:23: error: missing terminating > character
1 | #include<bits/stdc++.h
| ^
|
s489911163 | p03636 | C | // luogu-judger-enable-o2
#include<bits/stdc++.h>
using namespace std;
char c[105];
int main()
{
// freopen(".in","r",stdin);
// freopen(".out","w",stdout);
gets(c);
cout<<c[0]<<strlen(c)-2<<c[strlen(c)-1];
return 0;
}
| main.c:2:9: fatal error: bits/stdc++.h: No such file or directory
2 | #include<bits/stdc++.h>
| ^~~~~~~~~~~~~~~
compilation terminated.
|
s079073852 | p03636 | C | // luogu-judger-enable-o2
#include<bits/stdc++.h>
using namespace std;
char c[105];
int main()
{
// freopen(".in","r",stdin);
// freopen(".out","w",stdout);
gets(c);
cout<<c[0]<<strlen(c)-2<<c[strlen(c)-1];
return 0;
}
| main.c:2:9: fatal error: bits/stdc++.h: No such file or directory
2 | #include<bits/stdc++.h>
| ^~~~~~~~~~~~~~~
compilation terminated.
|
s049212026 | p03636 | C++ | // luogu-judger-enable-o2
#include<bits/stdc++.h>
using namespace std;
char c[105];
int main()
{
// freopen(".in","r",stdin);
// freopen(".out","w",stdout);
gets(c);
cout<<c[0]<<strlen(c)-2<<c[strlen(c)-1];
return 0;
}
| a.cc: In function 'int main()':
a.cc:9:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
9 | gets(c);
| ^~~~
| getw
|
s783757065 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std ;
int main(){
string S ;
cin >> S ;
size_t size=S.length()
cout << S[0] << size-2 << S[size-1];
}
| a.cc: In function 'int main()':
a.cc:10:3: error: expected ',' or ';' before 'cout'
10 | cout << S[0] << size-2 << S[size-1];
| ^~~~
|
s571697586 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std ;
int main(){
string S ;
cin >> S ;
cout << S[0] << string.length(S)-2 << S[string.length(S)-1];
}
| a.cc: In function 'int main()':
a.cc:8:25: error: expected primary-expression before '.' token
8 | cout << S[0] << string.length(S)-2 << S[string.length(S)-1];
| ^
a.cc:8:49: error: expected primary-expression before '.' token
8 | cout << S[0] << string.length(S)-2 << S[string.length(S)-1];
| ^
|
s250784866 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std ;
int main(){
string S ;
cin >> S ;
cout << S[0] << str.length(S)-2 << S[str.length(S)-1];
}
| a.cc: In function 'int main()':
a.cc:8:19: error: 'str' was not declared in this scope; did you mean 'std'?
8 | cout << S[0] << str.length(S)-2 << S[str.length(S)-1];
| ^~~
| std
|
s321708516 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std ;
int main(){
string S ;
cin >> S ;
cout << S[0] << length(S)-2 << S[length(S)-1];
}
| a.cc: In function 'int main()':
a.cc:8:19: error: 'length' was not declared in this scope
8 | cout << S[0] << length(S)-2 << S[length(S)-1];
| ^~~~~~
|
s991477583 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std ;
int main(){
string S ;
cin >> S ;
cout << S[0] << long(S)-2 << S[long(S)-1];
}
| a.cc: In function 'int main()':
a.cc:8:19: error: invalid cast from type 'std::string' {aka 'std::__cxx11::basic_string<char>'} to type 'long int'
8 | cout << S[0] << long(S)-2 << S[long(S)-1];
| ^~~~~~~
a.cc:8:34: error: invalid cast from type 'std::string' {aka 'std::__cxx11::basic_string<char>'} to type 'long int'
8 | cout << S[0] << long(S)-2 << S[long(S)-1];
| ^~~~~~~
|
s930953830 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main(){
string s;cin>>s;
cout<<s[0]<s.size()-2<<s[s.length()-1]<<endl;
} | a.cc: In function 'int main()':
a.cc:5:47: error: invalid operands of types 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} and '<unresolved overloaded function type>' to binary 'operator<<'
5 | cout<<s[0]<s.size()-2<<s[s.length()-1]<<endl;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
|
s769591395 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main(){
string s;cin>>s;
cout<<s[0]<s.length()-2<<s[s.length()-1]<<endl;
} | a.cc: In function 'int main()':
a.cc:5:49: error: invalid operands of types 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} and '<unresolved overloaded function type>' to binary 'operator<<'
5 | cout<<s[0]<s.length()-2<<s[s.length()-1]<<endl;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
|
s987087486 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char s[10000];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
|
s281486289 | p03636 | C++ | #include <iostream>
using namespace std;
int main(){
string s;
cin >> s;
int size = s.size()
int count = size - 2;
cout << s.at(0) << count << s.at(size -1) << endl;
}
| a.cc: In function 'int main()':
a.cc:7:3: error: expected ',' or ';' before 'int'
7 | int count = size - 2;
| ^~~
a.cc:8:22: error: 'count' was not declared in this scope
8 | cout << s.at(0) << count << s.at(size -1) << endl;
| ^~~~~
|
s121323468 | p03636 | C++ | #include"cstring"
#include"iostream"
using namespace std;
char s[100];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
} | a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
7 | gets(s);
| ^~~~
| getw
|
s524479542 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
cin>>s;
cout<<s[0]<<s.size()-2<<s[s.size()-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:14: error: 's' was not declared in this scope
6 | cin>>s;
| ^
|
s412620091 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
char x[101];
int l;
int main()
{
cin>>x;
l=x.size();
cout<<x[0]<<l-2<<x[l-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:8:13: error: request for member 'size' in 'x', which is of non-class type 'char [101]'
8 | l=x.size();
| ^~~~
|
s986723007 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char s[10000];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
6 | gets(s);
| ^~~~
| getw
|
s521807262 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
string s;
int a;
int main()
{
cin>>s;
a=s.size();
cout<<s[0]<<len-2<<s[len-1];
return 0;
}
| a.cc: In function 'int main()':
a.cc:9:17: error: 'len' was not declared in this scope
9 | cout<<s[0]<<len-2<<s[len-1];
| ^~~
|
s097892336 | p03636 | C++ | #include<string>
#include<cstring>
#include<iostream>
using namespace std;
char s[10000];
int main()
{
gets(s);
cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];
return 0;
} | a.cc: In function 'int main()':
a.cc:8:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
8 | gets(s);
| ^~~~
| getw
|
s622392289 | p03636 | C++ | #include<bits/stdc++.h>
char s[102];
int main(){gets(s);std::cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];} | a.cc: In function 'int main()':
a.cc:3:12: error: 'gets' was not declared in this scope; did you mean 'getw'?
3 | int main(){gets(s);std::cout<<s[0]<<strlen(s)-2<<s[strlen(s)-1];}
| ^~~~
| getw
|
s124841069 | p03636 | C++ | #include<iostream>
#include<cstdio>
#include<cstring>
#include<string>
#include<vector>
#include<queue>
#include<deque>
#include<algorithm>
#include<iomanip>
#include<cstdlib>
#include<cstdio>
#include<cmath>
using namespace std;
string s;
int main(){
cin >> s;
cout << s[0] << strlen(s) - 2 << s[strlen(s) - 1];
return 0;
} | a.cc: In function 'int main()':
a.cc:19:28: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
19 | cout << s[0] << strlen(s) - 2 << s[strlen(s) - 1];
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/14/cstring:43,
from a.cc:3:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
a.cc:19:47: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
19 | cout << s[0] << strlen(s) - 2 << s[strlen(s) - 1];
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
|
s427817388 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
#define rep1(i,n) for(int i=1;i<(int)(n);i++)
#define fs first
#define sc second
typedef pair<ll, ll> l_l;
#define EPS (1e-7)
#define INF (1e9)
#define PI (acos(-1))
int main(){
string s;
cin>>s;
string a=s.size()-2;
cout<<s[0]+a+s[s.size()-1]<<endl;
} | a.cc: In function 'int main()':
a.cc:16:20: error: conversion from 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
16 | string a=s.size()-2;
| ~~~~~~~~^~
|
s680550796 | p03636 | C++ | // luogu-judger-enable-o2
| /usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
|
s507424082 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main() {
string S;
cin >> S;
int a = S.length();
cout << S[0] + '' + (a - 2) + '' + S[a - 1] << endl;
} | a.cc:9:20: error: empty character constant
9 | cout << S[0] + '' + (a - 2) + '' + S[a - 1] << endl;
| ^~
a.cc:9:35: error: empty character constant
9 | cout << S[0] + '' + (a - 2) + '' + S[a - 1] << endl;
| ^~
|
s938383235 | p03636 | C++ | #include<iostream>
#include <string>
using namespace std;
int main(void){
long string str;
cin >> str ;
int i = 0;
while(str[i] != '\0'){
i ++ ;
}
cout << str[0] << i-2 << str[i-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:7:15: error: expected initializer before 'str'
7 | long string str;
| ^~~
a.cc:8:10: error: 'str' was not declared in this scope; did you mean 'std'?
8 | cin >> str ;
| ^~~
| std
|
s476537212 | p03636 | C++ | #include<iostream>
using namespace
int main(void){
char str[] ;
cin >> str ;
int i = 0;
while(str[i] != "\0"){
i ++ ;
}
cout << str[0] << i-2 << str[i]<<endl;
return 0;
} | a.cc:4:1: error: expected identifier before 'int'
4 | int main(void){
| ^~~
a.cc:2:16: error: expected ';' before 'int'
2 | using namespace
| ^
| ;
3 |
4 | int main(void){
| ~~~
a.cc: In function 'int main()':
a.cc:6:8: error: storage size of 'str' isn't known
6 | char str[] ;
| ^~~
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
7 | cin >> str ;
| ^~~
| 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:16:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
16 | cout << str[0] << i-2 << str[i]<<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:16:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
16 | cout << str[0] << i-2 << str[i]<<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)
| ^~~~
|
s570880566 | p03636 | C++ | #include<iostream>
using namespace
int main(){
char str[] ;
cin >> str ;
int i = 0;
while(str[i] != "\0"){
i ++ ;
}
cout << str[0] << i-2 << str[i]<<endl;
return 0;
} | a.cc:4:1: error: expected identifier before 'int'
4 | int main(){
| ^~~
a.cc:2:16: error: expected ';' before 'int'
2 | using namespace
| ^
| ;
3 |
4 | int main(){
| ~~~
a.cc: In function 'int main()':
a.cc:6:8: error: storage size of 'str' isn't known
6 | char str[] ;
| ^~~
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
7 | cin >> str ;
| ^~~
| 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:16:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
16 | cout << str[0] << i-2 << str[i]<<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:16:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
16 | cout << str[0] << i-2 << str[i]<<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)
| ^~~~
|
s615132757 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int n = s.size();
cout << s[0] + n + s[s.size] << endl;
}
| a.cc: In function 'int main()':
a.cc:8:23: error: invalid use of non-static member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
8 | cout << s[0] + n + s[s.size] << endl;
| ^
In file included from /usr/include/c++/14/string:54,
from /usr/include/c++/14/bitset:52,
from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
from a.cc:1:
/usr/include/c++/14/bits/basic_string.h:1076:7: note: declared here
1076 | size() const _GLIBCXX_NOEXCEPT
| ^~~~
|
s416272377 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
string a;
int len;
cin>>a;
len=a.size();
cout<<a[0]<<len-2<<a[len-1]
} | a.cc: In function 'int main()':
a.cc:9:36: error: expected ';' before '}' token
9 | cout<<a[0]<<len-2<<a[len-1]
| ^
| ;
10 | }
| ~
|
s181694556 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin>>s;
cout<<s[0]+itoa(s.size()-2)+s[s.size()-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:7:16: error: 'itoa' was not declared in this scope
7 | cout<<s[0]+itoa(s.size()-2)+s[s.size()-1]<<endl;
| ^~~~
|
s297720610 | p03636 | C++ | #include<bits/sdtdc++.h>
using namespace std;
int main(){
char c,k;
int ans=0;
scanf("%c",&c);
printf("%c",c);
while(c=getchar()){
if(c==' '||c=='\n')
break;
ans++;
k=c;
}
printf("%d%c",ans-1,k);
return 0;
} | a.cc:1:9: fatal error: bits/sdtdc++.h: No such file or directory
1 | #include<bits/sdtdc++.h>
| ^~~~~~~~~~~~~~~~
compilation terminated.
|
s949188303 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
char a[10000]
cin>>s;
cout<<a[0]<<strlen(a)-2<<a[strlen(a)-1];
return 0; | a.cc: In function 'int main()':
a.cc:5:5: error: expected initializer before 'cin'
5 | cin>>s;
| ^~~
a.cc:6:11: error: 'a' was not declared in this scope
6 | cout<<a[0]<<strlen(a)-2<<a[strlen(a)-1];
| ^
a.cc:7:14: error: expected '}' at end of input
7 | return 0;
| ^
a.cc:3:11: note: to match this '{'
3 | int main(){
| ^
|
s609335456 | p03636 | C++ | #include <string>
#include <iostream>
string st;
int main()
{
cin>>st;
cout<<st[0]<<st.size()-2<<st[st.size()-1]<<endl;
} | a.cc:4:1: error: 'string' does not name a type; did you mean 'stdin'?
4 | string st;
| ^~~~~~
| stdin
a.cc: In function 'int main()':
a.cc:8:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
8 | cin>>st;
| ^~~
| std::cin
In file included from a.cc:2:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
62 | extern istream cin; ///< Linked to standard input
| ^~~
a.cc:8:10: error: 'st' was not declared in this scope; did you mean 'std'?
8 | cin>>st;
| ^~
| std
a.cc:9:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
9 | cout<<st[0]<<st.size()-2<<st[st.size()-1]<<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:9:48: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
9 | cout<<st[0]<<st.size()-2<<st[st.size()-1]<<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)
| ^~~~
|
s161722146 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
cout << s[0] << (s.size - 2) << s[(s.size - 1)] << endl;
}
| a.cc: In function 'int main()':
a.cc:9:28: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
9 | cout << s[0] << (s.size - 2) << s[(s.size - 1)] << endl;
| ~~^~~~
| ()
a.cc:9:46: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
9 | cout << s[0] << (s.size - 2) << s[(s.size - 1)] << endl;
| ~~^~~~
| ()
|
s021363375 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
cout << s[0] << s.size - 2 << s[s.size - 1] << endl;
}
| a.cc: In function 'int main()':
a.cc:9:27: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
9 | cout << s[0] << s.size - 2 << s[s.size - 1] << endl;
| ~~^~~~
| ()
a.cc:9:43: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
9 | cout << s[0] << s.size - 2 << s[s.size - 1] << endl;
| ~~^~~~
| ()
|
s323839849 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main() {
string s;
cin>>s;
cout<<s[0]<<s.size()-2<<c[s.size()-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:6:33: error: 'c' was not declared in this scope
6 | cout<<s[0]<<s.size()-2<<c[s.size()-1]<<endl;
| ^
|
s539550863 | p03636 | C++ | #include<cstdio>
#include<cstring>
using namespace std;
int main(){
string s;
getline(cin,s);
printf("%c%d%c",s[0],s.length()-2,s[s.length()-1]);
return 0;
} | a.cc: In function 'int main()':
a.cc:5:5: error: 'string' was not declared in this scope
5 | string s;
| ^~~~~~
a.cc:3:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
2 | #include<cstring>
+++ |+#include <string>
3 | using namespace std;
a.cc:6:13: error: 'cin' was not declared in this scope
6 | getline(cin,s);
| ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
2 | #include<cstring>
+++ |+#include <iostream>
3 | using namespace std;
a.cc:6:17: error: 's' was not declared in this scope
6 | getline(cin,s);
| ^
|
s077463408 | p03636 | C | #include<stdio.h>
#include<string.h>
int main(){
char s[101];
scnaf("%s", s);
int str = strlen(s);
printf("%c%d%c\n", s[0],str-2,s[str-1]);
return 0;
} | main.c: In function 'main':
main.c:7:2: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
7 | scnaf("%s", s);
| ^~~~~
| scanf
|
s538394536 | p03636 | C | #include<stdio.h>
int str_length(const char s[]){
int len = 0;
while(s[len])
len++;
return len;
}
int main(){
char s[101];
scnaf("%s", s);
int strlen = str_length(s);
printf("%c%d%c\n", s[0],strlen-2,s[strlen-1]);
return 0;
} | main.c: In function 'main':
main.c:11:2: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
11 | scnaf("%s", s);
| ^~~~~
| scanf
|
s529866128 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
cout << s.begin() << s.size() - 2 << s.end() << endl;
}
| a.cc: In function 'int main()':
a.cc:8:8: error: no match for 'operator<<' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'std::__cxx11::basic_string<char>::iterator')
8 | cout << s.begin() << s.size() - 2 << s.end() << endl;
| ~~~~ ^~ ~~~~~~~~~
| | |
| | std::__cxx11::basic_string<char>::iterator
| std::ostream {aka std::basic_ostream<char>}
In file included from /usr/include/c++/14/istream:41,
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/ostream:116:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ostream_type& (*)(__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:116:36: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&)' {aka 'std::basic_ostream<char>& (*)(std::basic_ostream<char>&)'}
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:125:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ios_type& (*)(__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; __ios_type = std::basic_ios<char>]'
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:125:32: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'}
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:135:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ^~~~~~~~
/usr/include/c++/14/ostream:135:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::ios_base& (*)(std::ios_base&)'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:174:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
174 | operator<<(long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:174:23: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long int'
174 | operator<<(long __n)
| ~~~~~^~~
/usr/include/c++/14/ostream:178:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
178 | operator<<(unsigned long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:178:32: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long unsigned int'
178 | operator<<(unsigned long __n)
| ~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:182:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
182 | operator<<(bool __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:182:23: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'bool'
182 | operator<<(bool __n)
| ~~~~~^~~
In file included from /usr/include/c++/14/ostream:1022:
/usr/include/c++/14/bits/ostream.tcc:96:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char; _Traits = std::char_traits<char>]'
96 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:97:22: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'short int'
97 | operator<<(short __n)
| ~~~~~~^~~
/usr/include/c++/14/ostream:189:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
189 | operator<<(unsigned short __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:189:33: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'short unsigned int'
189 | operator<<(unsigned short __n)
| ~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/ostream.tcc:110:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char; _Traits = std::char_traits<char>]'
110 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:111:20: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'int'
111 | operator<<(int __n)
| ~~~~^~~
/usr/include/c++/14/ostream:200:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
200 | operator<<(unsigned int __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:200:31: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'unsigned int'
200 | operator<<(unsigned int __n)
| ~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:211:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
211 | operator<<(long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:211:28: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long long int'
211 | operator<<(long long __n)
| ~~~~~~~~~~^~~
/usr/include/c++/14/ostream:215:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
215 | operator<<(unsigned long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:215:37: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long long unsigned int'
215 | operator<<(unsigned long long __n)
| ~~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:231:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
231 | operator<<(double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:231:25: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'double'
231 | operator<<(double __f)
| ~~~~~~~^~~
/usr/include/c++/14/ostream:235:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(float) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
235 | operator<<(float __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:235:24: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'float'
235 | operator<<(float __f)
| ~~~~~~^~~
/usr/include/c++/14/ostream:243:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
243 | operator<<(long double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:243:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long double'
243 | operator<<(long double __f)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:301:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(const void*) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
301 | operator<<(const void* __p)
| ^~~~~~~~
/usr/include/c++/14/ostream:301:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'const void*'
301 | operator<<(const void* __p)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:306: |
s577714049 | p03636 | C++ | #include<algorithm>
#include <iostream>
#include<cstdio>
#include<cmath>
#include<iomanip>
#include<string>
using namespace std;
int main() {
string s;
cin >> s;
int l = s.length();
cout << s[0] << l << s[l - 1] << endl;
}
return 0;
} | a.cc:21:9: error: expected unqualified-id before 'return'
21 | return 0;
| ^~~~~~
a.cc:22:1: error: expected declaration before '}' token
22 | }
| ^
|
s124519728 | p03636 | C++ | #include <iostream>
#include <string>
using name space
int main() {
string s;
cin >> s;
int num = s.length();
cout << s[0] << num-2 << s[num-1] << endl;
} | a.cc:3:7: error: expected nested-name-specifier before 'name'
3 | using name space
| ^~~~
|
s516448652 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
char a[1000001];
int la;
int main()
{
cin>>a;
la=strlen(a);
cout<<a[0]<<la-2<<a[n-1]<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:9:29: error: 'n' was not declared in this scope; did you mean 'yn'?
9 | cout<<a[0]<<la-2<<a[n-1]<<endl;
| ^
| yn
|
s328046045 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int N = S.length() - 2;
cout << S[0] << N << S[N+1] << end;
} | a.cc: In function 'int main()':
a.cc:8:31: error: no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and '<unresolved overloaded function type>')
8 | cout << S[0] << N << S[N+1] << end;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
In file included from /usr/include/c++/14/istream:41,
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/ostream:116:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ostream_type& (*)(__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:116:36: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&)' {aka 'std::basic_ostream<char>& (*)(std::basic_ostream<char>&)'}
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:125:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ios_type& (*)(__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; __ios_type = std::basic_ios<char>]'
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:125:32: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'}
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:135:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ^~~~~~~~
/usr/include/c++/14/ostream:135:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::ios_base& (*)(std::ios_base&)'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:174:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
174 | operator<<(long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:174:23: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long int'
174 | operator<<(long __n)
| ~~~~~^~~
/usr/include/c++/14/ostream:178:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
178 | operator<<(unsigned long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:178:32: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long unsigned int'
178 | operator<<(unsigned long __n)
| ~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:182:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
182 | operator<<(bool __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:182:23: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'bool'
182 | operator<<(bool __n)
| ~~~~~^~~
In file included from /usr/include/c++/14/ostream:1022:
/usr/include/c++/14/bits/ostream.tcc:96:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char; _Traits = std::char_traits<char>]'
96 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:97:22: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'short int'
97 | operator<<(short __n)
| ~~~~~~^~~
/usr/include/c++/14/ostream:189:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
189 | operator<<(unsigned short __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:189:33: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'short unsigned int'
189 | operator<<(unsigned short __n)
| ~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/ostream.tcc:110:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char; _Traits = std::char_traits<char>]'
110 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:111:20: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'int'
111 | operator<<(int __n)
| ~~~~^~~
/usr/include/c++/14/ostream:200:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
200 | operator<<(unsigned int __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:200:31: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'unsigned int'
200 | operator<<(unsigned int __n)
| ~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:211:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
211 | operator<<(long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:211:28: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long long int'
211 | operator<<(long long __n)
| ~~~~~~~~~~^~~
/usr/include/c++/14/ostream:215:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
215 | operator<<(unsigned long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:215:37: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long long unsigned int'
215 | operator<<(unsigned long long __n)
| ~~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:231:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
231 | operator<<(double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:231:25: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'double'
231 | operator<<(double __f)
| ~~~~~~~^~~
/usr/include/c++/14/ostream:235:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(float) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
235 | operator<<(float __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:235:24: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'float'
235 | operator<<(float __f)
| ~~~~~~^~~
/usr/include/c++/14/ostream:243:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
243 | operator<<(long double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:243:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long double'
243 | operator<<(long double __f)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:301:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(const void*) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
301 | operator<<(const void* __p)
| ^~~~~~~~
/usr/include/c++/14/ostream:301:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'const void*'
301 | operator<<(const void* __p)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:306:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::nullptr_t) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; std::nullptr_t = st |
s701720063 | p03636 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int N = S.size() - 2;
cout << S[0] << N << S[N+1] << end;
} | a.cc: In function 'int main()':
a.cc:8:31: error: no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and '<unresolved overloaded function type>')
8 | cout << S[0] << N << S[N+1] << end;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
In file included from /usr/include/c++/14/istream:41,
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/ostream:116:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ostream_type& (*)(__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:116:36: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&)' {aka 'std::basic_ostream<char>& (*)(std::basic_ostream<char>&)'}
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:125:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ios_type& (*)(__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; __ios_type = std::basic_ios<char>]'
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:125:32: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'}
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:135:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ^~~~~~~~
/usr/include/c++/14/ostream:135:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::ios_base& (*)(std::ios_base&)'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:174:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
174 | operator<<(long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:174:23: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long int'
174 | operator<<(long __n)
| ~~~~~^~~
/usr/include/c++/14/ostream:178:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
178 | operator<<(unsigned long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:178:32: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long unsigned int'
178 | operator<<(unsigned long __n)
| ~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:182:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
182 | operator<<(bool __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:182:23: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'bool'
182 | operator<<(bool __n)
| ~~~~~^~~
In file included from /usr/include/c++/14/ostream:1022:
/usr/include/c++/14/bits/ostream.tcc:96:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char; _Traits = std::char_traits<char>]'
96 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:97:22: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'short int'
97 | operator<<(short __n)
| ~~~~~~^~~
/usr/include/c++/14/ostream:189:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
189 | operator<<(unsigned short __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:189:33: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'short unsigned int'
189 | operator<<(unsigned short __n)
| ~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/ostream.tcc:110:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char; _Traits = std::char_traits<char>]'
110 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:111:20: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'int'
111 | operator<<(int __n)
| ~~~~^~~
/usr/include/c++/14/ostream:200:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
200 | operator<<(unsigned int __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:200:31: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'unsigned int'
200 | operator<<(unsigned int __n)
| ~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:211:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
211 | operator<<(long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:211:28: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long long int'
211 | operator<<(long long __n)
| ~~~~~~~~~~^~~
/usr/include/c++/14/ostream:215:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
215 | operator<<(unsigned long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:215:37: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long long unsigned int'
215 | operator<<(unsigned long long __n)
| ~~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:231:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
231 | operator<<(double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:231:25: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'double'
231 | operator<<(double __f)
| ~~~~~~~^~~
/usr/include/c++/14/ostream:235:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(float) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
235 | operator<<(float __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:235:24: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'float'
235 | operator<<(float __f)
| ~~~~~~^~~
/usr/include/c++/14/ostream:243:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
243 | operator<<(long double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:243:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'long double'
243 | operator<<(long double __f)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:301:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(const void*) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
301 | operator<<(const void* __p)
| ^~~~~~~~
/usr/include/c++/14/ostream:301:30: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'const void*'
301 | operator<<(const void* __p)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:306:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::nullptr_t) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; std::nullptr_t = st |
s671121931 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s;
cin >> s;
cout << s[0](s.size - 2)s[n] << endl;
return 0;
}
| a.cc: In function 'int main()':
a.cc:8:18: error: invalid use of member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]' (did you forget the '()' ?)
8 | cout << s[0](s.size - 2)s[n] << endl;
| ~~^~~~
| ()
a.cc:8:26: error: expression cannot be used as a function
8 | cout << s[0](s.size - 2)s[n] << endl;
| ^
|
s408278389 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main()
{
string s;
cin >> s;
int i =s,length();
cout << s[1] << i-2 <<s[-1] <<endl;
} | a.cc: In function 'int main()':
a.cc:8:10: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'int' in initialization
8 | int i =s,length();
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
a.cc:8:18: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
8 | int i =s,length();
| ^~
a.cc:8:18: note: remove parentheses to default-initialize a variable
8 | int i =s,length();
| ^~
| --
a.cc:8:18: note: or replace parentheses with braces to value-initialize a variable
|
s407431477 | p03636 | C++ | #include <iostream>
#include <string>
using namespace std;
int main();
{
string s;
cin >> s;
int i;
i = len(s)-2;
string(i);
cout << s[0] + i + s[-1] <<endl;
} | a.cc:5:1: error: expected unqualified-id before '{' token
5 | {
| ^
|
s991615465 | p03636 | C++ | #include <iostream>
#include<algorithm>
#include<map>
using namespace std;
int main(void){
string s;
cout << s[0] << length(s)-2 << s[length(s)];
return 0;
} | a.cc: In function 'int main()':
a.cc:11:25: error: 'length' was not declared in this scope
11 | cout << s[0] << length(s)-2 << s[length(s)];
| ^~~~~~
|
s004676418 | p03636 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
string s; cin>>s;
int t=s.size()-2;
cout<<s[0]<<t<<s.end()<<endl;
} | a.cc: In function 'int main()':
a.cc:7:16: error: no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and 'std::__cxx11::basic_string<char>::iterator')
7 | cout<<s[0]<<t<<s.end()<<endl;
| ~~~~~~~~~~~~~^~~~~~~~~
| | |
| | std::__cxx11::basic_string<char>::iterator
| std::basic_ostream<char>
In file included from /usr/include/c++/14/istream:41,
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/ostream:116:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ostream_type& (*)(__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:116:36: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&)' {aka 'std::basic_ostream<char>& (*)(std::basic_ostream<char>&)'}
116 | operator<<(__ostream_type& (*__pf)(__ostream_type&))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:125:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ios_type& (*)(__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; __ios_type = std::basic_ios<char>]'
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ^~~~~~~~
/usr/include/c++/14/ostream:125:32: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'}
125 | operator<<(__ios_type& (*__pf)(__ios_type&))
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:135:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ^~~~~~~~
/usr/include/c++/14/ostream:135:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'std::ios_base& (*)(std::ios_base&)'
135 | operator<<(ios_base& (*__pf) (ios_base&))
| ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/ostream:174:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
174 | operator<<(long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:174:23: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long int'
174 | operator<<(long __n)
| ~~~~~^~~
/usr/include/c++/14/ostream:178:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
178 | operator<<(unsigned long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:178:32: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long unsigned int'
178 | operator<<(unsigned long __n)
| ~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:182:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
182 | operator<<(bool __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:182:23: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'bool'
182 | operator<<(bool __n)
| ~~~~~^~~
In file included from /usr/include/c++/14/ostream:1022:
/usr/include/c++/14/bits/ostream.tcc:96:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char; _Traits = std::char_traits<char>]'
96 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:97:22: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'short int'
97 | operator<<(short __n)
| ~~~~~~^~~
/usr/include/c++/14/ostream:189:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
189 | operator<<(unsigned short __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:189:33: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'short unsigned int'
189 | operator<<(unsigned short __n)
| ~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/bits/ostream.tcc:110:5: note: candidate: 'std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char; _Traits = std::char_traits<char>]'
110 | basic_ostream<_CharT, _Traits>::
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/ostream.tcc:111:20: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'int'
111 | operator<<(int __n)
| ~~~~^~~
/usr/include/c++/14/ostream:200:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
200 | operator<<(unsigned int __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:200:31: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'unsigned int'
200 | operator<<(unsigned int __n)
| ~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:211:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
211 | operator<<(long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:211:28: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long long int'
211 | operator<<(long long __n)
| ~~~~~~~~~~^~~
/usr/include/c++/14/ostream:215:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
215 | operator<<(unsigned long long __n)
| ^~~~~~~~
/usr/include/c++/14/ostream:215:37: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long long unsigned int'
215 | operator<<(unsigned long long __n)
| ~~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:231:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
231 | operator<<(double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:231:25: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'double'
231 | operator<<(double __f)
| ~~~~~~~^~~
/usr/include/c++/14/ostream:235:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(float) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
235 | operator<<(float __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:235:24: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'float'
235 | operator<<(float __f)
| ~~~~~~^~~
/usr/include/c++/14/ostream:243:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long double) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
243 | operator<<(long double __f)
| ^~~~~~~~
/usr/include/c++/14/ostream:243:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'long double'
243 | operator<<(long double __f)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:301:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(const void*) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]'
301 | operator<<(const void* __p)
| ^~~~~~~~
/usr/include/c++/14/ostream:301:30: note: no known conversion for argument 1 from 'std::__cxx11::basic_string<char>::iterator' to 'const void*'
301 | operator<<(const void* __p)
| ~~~~~~~~~~~~^~~
/usr/include/c++/14/ostream:306:7: note: candidate: 'std::basic_ostrea |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.