bubblesort2.cpp: In function 'int main()':
bubblesort2.cpp:4:34: error: 'stdin' was not declared in this scope
4 | freopen("bubblesort2.in", "r", stdin);
| ^~~~~
bubblesort2.cpp:1:1: note: 'stdin' is defined in header '<cstdio>'; did you forget to '#include <cstdio>'?
+++ |+#include <cstdio>
1 |
bubblesort2.cpp:4:3: error: 'freopen' was not declared in this scope
4 | freopen("bubblesort2.in", "r", stdin);
| ^~~~~~~
bubblesort2.cpp:5:35: error: 'stdout' was not declared in this scope
5 | freopen("bubblesort2.out", "w", stdout);
| ^~~~~~
bubblesort2.cpp:5:35: note: 'stdout' is defined in header '<cstdio>'; did you forget to '#include <cstdio>'?
bubblesort2.cpp:7:3: error: 'cin' was not declared in this scope
7 | cin.sync_with_stdio(0);
| ^~~
bubblesort2.cpp:10:3: error: 'vector' was not declared in this scope
10 | vector<int> a;
| ^~~~~~
bubblesort2.cpp:10:10: error: expected primary-expression before 'int'
10 | vector<int> a;
| ^~~
bubblesort2.cpp:11:10: error: expected primary-expression before 'int'
11 | vector<int> inds;
| ^~~
bubblesort2.cpp:12:10: error: expected primary-expression before 'int'
12 | vector<int> vals;
| ^~~
bubblesort2.cpp:14:3: error: 'a' was not declared in this scope
14 | a = {1, 2, 3, 4};
| ^
bubblesort2.cpp:15:3: error: 'inds' was not declared in this scope
15 | inds = {0, 2};
| ^~~~
bubblesort2.cpp:16:3: error: 'vals' was not declared in this scope
16 | vals = {3, 1};
| ^~~~
bubblesort2.cpp:18:10: error: expected primary-expression before 'int'
18 | vector<int> pr = countScans(a, inds, vals);
| ^~~
bubblesort2.cpp:20:9: error: 'pr' was not declared in this scope
20 | debug(pr);
| ^~
bubblesort2.cpp:20:3: error: 'debug' was not declared in this scope
20 | debug(pr);
| ^~~~~