Problem bracketex
User ethantanaki
Submission Time 2026-04-18 09:47:50
Score 0
Max Time N/A
Max Memory N/A

Compile Error

bracketex.cpp: In function ‘int main()’:
bracketex.cpp:9:12: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
9 | if (c == "(" or c == "[" or c == "{")
| ^~~
bracketex.cpp:9:24: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
9 | if (c == "(" or c == "[" or c == "{")
| ^~~
bracketex.cpp:9:36: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
9 | if (c == "(" or c == "[" or c == "{")
| ^~~
bracketex.cpp:15:13: error: cannot convert ‘std::stack<int>::empty’ from type ‘bool (std::stack<int>::)() const’ to type ‘bool’
15 | if (s.empty) cout << "Valid";
| ^