0
Why this code does not work pls help me
I have done this code with if statements but with switch it is giving an error does anyone know WHY https://code.sololearn.com/cm5EAVnqTgH1/?ref=app
9 ответов
+ 9
some basic errors like :
1. switch(n); it should be switch(n){ }
2.U forgot ; after return 0.
3.added unnecessary { } in line 5
https://code.sololearn.com/cyz48WH4h6Aa/?ref=app
+ 5
You've written that:
switch (n);{
...
}
but you have to write a switch statement like that:
switch(n){
...
}
+ 3
<3
+ 2
Thank you for doing this M Squared
+ 1
thanks to all who have answered. you guys helped me very much thanks