Problem brick
User tdb60
Submission Time 2023-11-14 15:04:53
Score 0
Max Time N/A
Max Memory N/A

Compile Error

brick.cpp: In function ‘int main()’:
brick.cpp:2:2: error: ‘ios’ has not been declared
2 | ios::sync_with_stdio(0);
| ^~~
brick.cpp:3:2: error: ‘cin’ was not declared in this scope
3 | cin.tie(0);
| ^~~
brick.cpp:5:1: error: ‘stack’ was not declared in this scope
5 | stack<int> stk;
| ^~~~~
brick.cpp:5:7: error: expected primary-expression before ‘int’
5 | stack<int> stk;
| ^~~
brick.cpp:9:11: error: ‘stk’ was not declared in this scope; did you mean ‘std’?
9 | while (!stk.empty() && stk.top() <= X) stk.pop();
| ^~~
| std
brick.cpp:10:3: error: ‘stk’ was not declared in this scope; did you mean ‘std’?
10 | stk.push(X);
| ^~~
| std
brick.cpp:12:10: error: ‘stk’ was not declared in this scope; did you mean ‘std’?
12 | while (!stk.empty()) {
| ^~~
| std
brick.