+ 2
Can someone tell me why this code doesn't work??
6 Respuestas
+ 5
For the sake of compatibility, prefer `&&` operator over the alias 'and'. Most C++ coders write boolean expressions using `&&` operator, while 'and' is an occasionally option.
+ 4
The "if" statement are comparing two senteces.
( compare1 ) "and" ( compare2 ) = boole result. //true or false
you wrote : "else if ( a >= 400 and <= 699){ "
observe the second compare sentence. it`s something missing. "699 <= ?(missing thing)"
ex.:
if ( a >= 400 and a <= 699)
I hope it helps.
Have a nice coding.
+ 4
+ 3
your first if and last else if !!!!!!!!
check those conditions
here they are overlapping at a = 1000
so if a= 1000 then it will the first result and then exit!!!!!
+ 2
Bruno Franco Explained Right Laiz N Because You’re Using and keyword so both of the conditions seems to be true but in right side expression you won’t compared your variable ‘a’ which arised error in your code.
Here I Made Corrections In Your Code 😊
https://code.sololearn.com/c779ViTLIPsW/?ref=app
+ 2
Ah ha..thanks so much guys, that totally cleared things up for me..