Problem foreveralone
User YongXin
Submission Time 2023-06-27 15:01:38
Score 0
Max Time N/A
Max Memory N/A

Compile Error

foreveralone.cpp: In function ‘int main()’:
foreveralone.cpp:7:13: error: the value of ‘n’ is not usable in a constant expression
7 | bitset<n> m;
| ^
foreveralone.cpp:5:9: note: ‘int n’ is not const
5 | int n,e,a,b;
| ^
foreveralone.cpp:7:13: note: in template argument for type ‘long unsigned int’
7 | bitset<n> m;
| ^
foreveralone.cpp:8:27: error: request for member ‘set’ in ‘m’, which is of non-class type ‘int’
8 | for(int i=0;i<n;++i)m.set(i);
| ^~~
foreveralone.cpp:12:19: error: request for member ‘test’ in ‘m’, which is of non-class type ‘int’
12 | if (m.test(a))m.reset(a);
| ^~~~
foreveralone.cpp:12:29: error: request for member ‘reset’ in ‘m’, which is of non-class type ‘int’
12 | if (m.test(a))m.reset(a);
| ^~~~