Problem shoes
User havinaaaaash
Submission Time 2024-12-05 16:17:27
Score 0
Max Time N/A
Max Memory N/A

Compile Error

shoes.cpp: In function ‘int count_swaps(int*)’:
shoes.cpp:6:11: error: expected ‘;’ before ‘==’ token
6 | for(int i == 0; i<S.length(); i+=2){
| ^~~
| ;
shoes.cpp:6:12: error: expected primary-expression before ‘==’ token
6 | for(int i == 0; i<S.length(); i+=2){
| ^~
shoes.cpp:6:22: error: request for member ‘length’ in ‘S’, which is of non-class type ‘int*’
6 | for(int i == 0; i<S.length(); i+=2){
| ^~~~~~
shoes.cpp:6:30: error: expected ‘)’ before ‘;’ token
6 | for(int i == 0; i<S.length(); i+=2){
| ~ ^
| )
shoes.cpp:6:32: error: ‘i’ was not declared in this scope
6 | for(int i == 0; i<S.length(); i+=2){
| ^