Hello everyone. Another dead end with the code. I can't figure out what the error is? | Sololearn: Learn to code for FREE!
Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
Kostenlose Lektion ausprobieren
+ 1

Hello everyone. Another dead end with the code. I can't figure out what the error is?

var score = parseInt(readLine(), 10) /* 88 and above => excellent 40-87 => good 0-39 => fail */ var x = 88; var y = 40; var z = 39; if (score <= z){console.log("fail")} else if (y <= score && score < x ){console.log("good")} else (score >= x) {console.log("exelent")}; // ваш код

6th Dec 2021, 5:10 PM
Николай
3 Antworten
+ 2
`else` does not accept any condition. And make sure you are printing the output as the task required of you. A different letter case ('fail' vs 'Fail') is a common problem that many had experienced.
6th Dec 2021, 5:48 PM
Ipang
+ 1
Thank you. My English is bad. The error was in the word 'excellent' VS 'exelent'. I am not attentive and illiterate
6th Dec 2021, 6:08 PM
Николай
+ 1
Just remember this, in anticipation of the next tasks, we learn by making mistakes, but it's okay we're only humans 👌
6th Dec 2021, 6:13 PM
Ipang