Submission #3816394


Source Code Expand

#include<iostream>
#include<string>
#include<cstdio>
#include<algorithm>
#include<cstdlib>
#include<cmath>
#include<vector>
#include<utility>
#include<queue>
#include<stack>
#include<set>
#include<map>
#include<unordered_set>
#include<bitset>
using namespace std;
#define INF 2147483647
#define MODE 1
#ifdef MODE
#define DEB(X) cout<< #X <<": "<<X<<" ";
#define ARDEB(i,X) cout<< #X <<"["<<i<<"]: "<<X[i]<<" ";
#define END cout<<endl;
#else
#define DEB(X) {}
#define ARDEB(i,X) {}
#define END {}
#endif
typedef long long int ll;

int main(){
	int a,b;
	cin>>a>>b;
	cin>>max(a,b)>>endl;
	
}

Submission Info

Submission Time
Task A - 正直者
User pit611kepo3054
Language C++14 (GCC 5.4.1)
Score 0
Code Size 625 Byte
Status CE

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:33:5: error: no match for ‘operator>>’ (operand types are ‘std::istream {aka std::basic_istream<char>}’ and ‘const int’)
  cin>>max(a,b)>>endl;
     ^
In file included from /usr/include/c++/5/iostream:40:0,
                 from ./Main.cpp:2:
/usr/include/c++/5/istream:120:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>] <near match>
       operator>>(__istream_type& (*__pf)(__istream_type&))
       ^
/usr/include/c++/5/istream:120:7: note:   conversion of argument 1 would be ill-formed:
./Main.cpp:33:10: error: invalid conversion from ‘int’ to ‘std::basic_istream<char>::__istream_type& (*)(std::basic_istream<char>::__istream_type&) {aka std::basi...