Problem | brick |
---|---|
User | YH |
Submission Time | 2024-02-04 20:38:10 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
brick.cpp: In function ‘int main()’:
brick.cpp:17:13: error: expected ‘}’ before ‘]’ token
17 | int stack{n];
| ~ ^
brick.cpp:17:13: error: expected ‘,’ or ‘;’ before ‘]’ token
brick.cpp:23:11: error: invalid types ‘int[int]’ for array subscript
23 | stack[d] = bricks[d];
| ^
brick.cpp:26:15: error: invalid types ‘int[int]’ for array subscript
26 | if (stack[0] <= bricks[d]) {
| ^
brick.cpp:27:12: error: invalid types ‘int[int]’ for array subscript
27 | stack[0] = bricks[d];
| ^
brick.cpp:32:13: error: invalid types ‘int[int]’ for array subscript
32 | stack[a] = stack[a-1];
| ^
brick.cpp:32:26: error: invalid types ‘int[int]’ for array subscript
32 | stack[a] = stack[a-1];
| ^
brick.cpp:34:12: error: invalid types ‘int[int]’ for array subscript
34 | stack[0] =