JAVASCRIPT · ОСНОВЫ · LESSON 08
Three options
else if · about 12 minutes
Learning with progressRead the summary for free. To save the work, log in to the account.
Type the code yourself
Type an example manually. Check the names, brackets and signs.
const stars = 4;
if (stars >= 5) {
console.log("Отлично");
} else if (stars >= 3) {
console.log("Хорошо");
} else {
console.log("Ещё раз");
}Open the editor for class workSolve it yourself
Create const stars = 2. At 5 or more, output «Супер», at 3 or more - «Хорошо», otherwise - «Попробуй ещё». Use if, else if and else.
The answer is hidden. Use similar examples from the lesson notes.
Opening up your homework