rect.cpp:7:1: error: 'vector' does not name a type
7 | vector<vector<int>> a;
| ^~~~~~
rect.cpp: In function 'bool check(int, int, int, int)':
rect.cpp:11:20: error: 'a' was not declared in this scope
11 | int t = min(min(a[i][c1-1], a[i][c2+1]), min(a[r1-1][j], a[r2+1][j]));
| ^
rect.cpp:11:16: error: 'min' was not declared in this scope; did you mean 'std::min'?
11 | int t = min(min(a[i][c1-1], a[i][c2+1]), min(a[r1-1][j], a[r2+1][j]));
| ^~~
| std::min
In file included from /usr/include/c++/9/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from rect.cpp:5:
/usr/include/c++/9/bits/stl_algo.h:3450:5: note: 'std::min' declared here
3450 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
rect.cpp:11:12: error: 'min' was not declared in this scope; did you mean 'std::min'?
11 | int t = min(min(a[i][c1-1], a[i][c2+1]), min(a[r1-1][j], a[r2+1][j]));
| ^~~
| std::min
In file included from /usr/include/c++/9/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from rect.cpp:5:
/usr/include/c++/9/bits/stl_algo.h:3450:5: note: 'std::min' declared here
3450 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
rect.cpp: In function 'void print(int, int, int, int)':
rect.cpp:20:4: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
20 | cout << a[i][j] << ' ';
| ^~~~
| std::cout
In file included from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:75,
from rect.cpp:5:
/usr/include/c++/9/iostream:61:18: note: 'std::cout' declared here
61 | extern ostream cout; /// Linked to standard output
| ^~~~
rect.cpp:20:12: error: 'a' was not declared in this scope
20 | cout << a[i][j] << ' ';
| ^
rect.cpp:21:4: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
21 | }cout << '\n';
| ^~~~
| std::cout
In file included from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:75,
from rect.cpp:5:
/usr/include/c++/9/iostream:61:18: note: 'std::cout' declared here
61 | extern ostream cout; /// Linked to standard output
| ^~~~
rect.cpp:22:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
22 | }cout << '\n';
| ^~~~
| std::cout
In file included from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:75,
from rect.cpp:5:
/usr/include/c++/9/iostream:61:18: note: 'std::cout' declared here
61 | extern ostream cout; /// Linked to standard output
| ^~~~
rect.cpp: At global scope:
rect.cpp:25:28: error: 'long long int count_rectangles' redeclared as different kind of entity
25 | long long count_rectangles(vector<vector<int>> a){
| ^~~~~~
In file included from rect.cpp:1:
rect.h:7:11: note: previous declaration 'long long int count_rectangles(std::vector<std::vector<int> >)'
7 | long long count_rectangles(std::vector<std::vector<int> > a);
| ^~~~~~~~~~~~~~~~
rect.cpp:25:28: error: 'vector' was not declared in this scope
25 | long long count_rectangles(vector<vector<int>> a){
| ^~~~~~
rect.cpp:25:28: note: suggested alternatives:
In file included from /usr/include/c++/9/vector:67,
from rect.h:5,
from rect.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:386:11: note: 'std::vector'
386 | class vector : protected _Vector_base<_Tp, _Alloc>
| ^~~~~~
In file included from rect.h:5,
from rect.cpp:1:
/usr/include/c++/9/vector:90:13: note: 'std::pmr::vector'
90 | using vector = std::vector<_Tp, polymorphic_allocator<_Tp>>;
| ^~~~~~
rect.cpp:25:35: error: 'vector' was not declared in this scope
25 | long long count_rectangles(vector<vector<int>> a){
| ^~~~~~
rect.cpp:25:35: note: suggested alternatives:
In file included from /usr/include/c++/9/vector:67,
from rect.h:5,
from rect.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:386:11: note: 'std::vector'
386 | class vector : protected _Vector_base<_Tp, _Alloc>
| ^~~~~~
In file included from rect.h:5,
from rect.cpp:1:
/usr/include/c++/9/vector:90:13: note: 'std::pmr::vector'
90 | using vector = std::vector<_Tp, polymorphic_allocator<_Tp>>;
| ^~~~~~
rect.cpp:25:42: error: expected primary-expression before 'int'
25 | long long count_rectangles(vector<vector<int>> a){
| ^~~