CSES - Putka Open 2015 – 6/6 - Results
Submission details
Task:Tutkat
Sender:
Submission time:2015-12-04 19:24:59 +0200
Language:C++
Status:COMPILE ERROR

Compiler report

input/code.cpp: In function 'int main()':
input/code.cpp:20:9: error: wrong number of template arguments (1, should be 4)
  map<pii> lol;
         ^
In file included from /usr/include/c++/4.9/map:61:0,
                 from /usr/include/x86_64-linux-gnu/c++/4.9/bits/stdc++.h:80,
                 from input/code.cpp:1:
/usr/include/c++/4.9/bits/stl_map.h:96:11: error: provided for 'template<class _Key, class _Tp, class _Compare, class _Alloc> class std::map'
     class map
           ^
input/code.cpp:20:14: error: invalid type in declaration before ';' token
  map<pii> lol;
              ^
input/code.cpp:23:7: error: request for member 'insert' in 'lol', which is of non-class type 'int'
   lol.insert({x, y});
       ^
input/code.cpp:26:9: error: request for member 'size' in 'lol', which is of non-class type 'int'
  if(lol.size() > 2){
         ^

Code

#include <bits/stdc++.h>

#define i64 long long
#define u64 unsigned long long
#define i32 int
#define u32 unsigned int

#define pii pair<int, int>
#define pll pair<long long, long long>

#define defmod 1000000007
using namespace std;


int main(){
	cin.sync_with_stdio(0);
	cin.tie(0);
	
	int n; cin >> n;
	map<pii> lol;
	for(int i = 0; i < n; i++){
		int x, y; cin >> x >> y;
		lol.insert({x, y});

	}
	if(lol.size() > 2){
		cout << "10-4" << endl;
	}
	else
		cout << "QAQ" << endl;
	return 0;
	
}