Problem bracketex
User Isabel123
Submission Time 2023-11-08 14:51:10
Score 0
Max Time N/A
Max Memory N/A

Compile Error

bracketex.cpp: In function ‘int main()’:
bracketex.cpp:20:22: error: expected ‘;’ before ‘}’ token
20 | s.push(v)
| ^
| ;
21 | } else if ((v == '}' || v == ']' || v == ')') && s.empty()) {
| ~
bracketex.cpp:22:21: error: expected ‘;’ before ‘}’ token
22 | cout << "Invalid"
| ^
| ;
23 | }
| ~
bracketex.cpp:25:8: error: expected ‘(’ before ‘s’
25 | if s.empty() {
| ^
| (
bracketex.cpp:27:7: error: ‘else’ without a previous ‘if’
27 | } else {
| ^~~~
bracketex.cpp:33:1: error: expected ‘}’ at end of input
33 | }
| ^
bracketex.cpp:4:11: note: to match this ‘{’
4 | int main(){
| ^