F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_39007042_2729.cpp: In function 'int main()':
0_0_39007042_2729.cpp:5:13: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int')
    5 |         cout>>40;
      |         ~~~~^~~~
      |         |     |
      |         |     int
      |         std::ostream {aka std::basic_ostream<char>}
0_0_39007042_2729.cpp:5:13: note: candidate: 'operator>>(int, int)' (built-in)
    5 |         cout>>40;
      |         ~~~~^~~~
0_0_39007042_2729.cpp:5:13: note:   no known conversion for argument 1 from 'std::ostream' {aka 'std::basic_ostream<char>'} to 'int'
In file included from .\stdc++.h:41:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/cstddef:130:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(byte, _IntegerType)'
  130 |     operator>>(byte __b, _IntegerType __shift) noexcept
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/cstddef:130:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:9: note:   cannot convert 'std::cout' (type 'std::ostream' {aka 'std::basic_ostream<char>'}) to type 'std::byte'
    5 |         cout>>40;
      |         ^~~~
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/string:55,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bitset:52,
                 from .\stdc++.h:52:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/basic_string.tcc:823: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>&)'
  823 |     operator>>(basic_istream<_CharT, _Traits>& __in,
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/basic_string.tcc:823:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bitset:1593:5: note: candidate: 'template<class _CharT, class _Traits, long long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, bitset<_Nb>&)'
 1593 |     operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x)
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bitset:1593:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
    5 |         cout>>40;
      |               ^~
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1106,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/sstream:40,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/complex:45,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/ccomplex:39,
                 from .\stdc++.h:127:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/istream.tcc:975:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT&)'
  975 |     operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c)
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/istream.tcc:975:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:846:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char&)'
  846 |     operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c)
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:846:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:851:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char&)'
  851 |     operator>>(basic_istream<char, _Traits>& __in, signed char& __c)
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:851:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:949:5: note: candidate: 'template<class _CharT, class _Traits, long long unsigned int _Num> std::basic_istream<_CharT, _Traits>& std::operator>>(basic_istream<_CharT, _Traits>&, _CharT (&)[_Num])'
  949 |     operator>>(basic_istream<_CharT, _Traits>& __in, _CharT (&__s)[_Num])
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:949:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<_CharT, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:958:5: note: candidate: 'template<class _Traits, long long unsigned int _Num> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, unsigned char (&)[_Num])'
  958 |     operator>>(basic_istream<char, _Traits>& __in, unsigned char (&__s)[_Num])
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:958:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:963:5: note: candidate: 'template<class _Traits, long long unsigned int _Num> std::basic_istream<char, _Traits>& std::operator>>(basic_istream<char, _Traits>&, signed char (&)[_Num])'
  963 |     operator>>(basic_istream<char, _Traits>& __in, signed char (&__s)[_Num])
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:963:5: note:   template argument deduction/substitution failed:
0_0_39007042_2729.cpp:5:15: note:   'std::ostream' {aka 'std::basic_ostream<char>'} is not derived from 'std::basic_istream<char, _Traits>'
    5 |         cout>>40;
      |               ^~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1096:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)'
 1096 |     operator>>(_Istream&& __is, _Tp&& __x)
      |     ^~~~~~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1096:5: note:   template argument deduction/substitution failed:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = int]':
0_0_39007042_2729.cpp:5:8:   required from here
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1096:5: error: template constraint failure for 'template<class _Is, class _Tp>  requires (__derived_from_ios_base<_Is>) && requires(_Is& __is, _Tp&& __t) {__is >> (forward<_Tp>)(__t);} using std::__rvalue_stream_extraction_t = _Is&&'
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1096:5: note: constraints not satisfied
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/unique_ptr.h:42,
                 from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/memory:78,
                 from .\stdc++.h:56:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/ostream: In substitution of 'template<class _Is, class _Tp>  requires (__derived_from_ios_base<_Is>) && requires(_Is& __is, _Tp&& __t) {__is >> (forward<_Tp>)(__t);} using std::__rvalue_stream_extraction_t = _Is&& [with _Is = std::basic_ostream<char>&; _Tp = int]':
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/istream:1096:5:   required by substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_ostream<char>&; _Tp = int]'
0_0_39007042_2729.cpp:5:8:   required from here
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/ostream:768:13:   required for the satisfaction of '__derived_from_ios_base<_Is>' [with _Is = std::basic_ostream<char, std::char_traits<char> >&]
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/ostream:768:39: note: the expression 'is_class_v<_Tp> [with _Tp = std::basic_ostream<char, std::char_traits<char> >&]' evaluated to 'false'
  768


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-23 09:52:04, Gzip enabled