Help!! | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
0

Help!!

function main() { var themNumber= 2 parseInt(readLine(), 10) /* 1 - Light 2 - Dark 3 - Nocturne 4 - Terminal 5 - Indigo */ // Your code here switch ("themeNumber"){ case 1: console.log ("Light"); break; case 2: console.log ("Dark"); break; case 3: console.log ("Nocturne"); break; case 4: console.log ("Terminal"); break; case 5: console.log ("Indigo"); } }

16th Sep 2022, 12:38 AM
Emmanuel Pena
2 ответов
+ 4
also in the switch statement . variable should not be in quotes .
16th Sep 2022, 1:19 AM
Prashanth Kumar
Prashanth Kumar - avatar
+ 3
1. Spelling mistake themeNumber, not themNumber 2. assign the variable as the input var themeNumber = parseInt(readLine(), 10);
16th Sep 2022, 1:15 AM
Gordon
Gordon - avatar