gap.cpp: In function 'long long int findGap(int, int)':
gap.cpp:7:3: error: 'vector' was not declared in this scope
vector<long long> v;
^~~~~~
gap.cpp:7:10: error: expected primary-expression before 'long'
vector<long long> v;
^~~~
gap.cpp:9:23: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, e, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 3 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:9:23: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, e, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 4 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:11:4: error: 'v' was not declared in this scope
v.push_back(mn);
^
gap.cpp:15:8: error: 'v' was not declared in this scope
sort(v.begin(), v.end());
^
gap.cpp:15:3: error: 'sort' was not declared in this scope
sort(v.begin(), v.end());
^~~~
gap.cpp:15:3: note: suggested alternative: 'short'
sort(v.begin(), v.end());
^~~~
short
gap.cpp:17:10: error: 'max' was not declared in this scope
res = max(res, v[i+1] - v[i]);
^~~
gap.cpp:17:10: note: suggested alternative: 'mx'
res = max(res, v[i+1] - v[i]);
^~~
mx
gap.cpp:20:22: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, e, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 3 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:20:22: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, e, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 4 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:22:3: error: 'vector' was not declared in this scope
vector<long long> v;
^~~~~~
gap.cpp:22:10: error: expected primary-expression before 'long'
vector<long long> v;
^~~~
gap.cpp:24:29: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, s + len, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 3 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:24:29: error: invalid conversion from 'long long int' to 'long long int*' [-fpermissive]
MinMax(s, s + len, mn, mx);
^
In file included from gap.cpp:1:0:
gap.h:1:6: note: initializing argument 4 of 'void MinMax(long long int, long long int, long long int*, long long int*)'
void MinMax(long long, long long, long long*, long long*);
^~~~~~
gap.cpp:26:5: error: 'v' was not declared in this scope
v.push_back(mn);
^
gap.cpp:31:8: error: 'v' was not declared in this scope
sort(v.begin(), v.end());
^
gap.cpp:31:3: error: 'sort' was not declared in this scope
sort(v.begin(), v.end());
^~~~
gap.cpp:31:3: note: suggested alternative: 'short'
sort(v.begin(), v.end());
^~~~
short
gap.cpp:34:10: error: 'max' was not declared in this scope
res = max(res, v[i+1] - v[i]);
^~~
gap.cpp:34:10: note: suggested alternative: 'mx'
res = max(res, v[i+1] - v[i]);
^~~
mx