What’s wrong with this JavaScript code?
It’s one of the coding exercise in SoloLearn, after//your code here is my coding , which I don’t know what went wrong in the JavaScript using “switch”. function main() { var themeNumber = parseInt(readLine(), 10) /* 1 - Light 2 - Dark 3 - Nocturne 4 - Terminal 5 - Indigo */ // Your code here switch (themeNumber){ case 1:document.write("Light"); break; case 2: document.write("Dark"); break; case 3: document.write("Nocturne"); break; case 4: document.write("Terminal"); break; default: document.write("Indigo");} } The question is : The user can choose the color theme for the browser: 1. Light 2. Dark 3. Nocturne 4. Terminal 5. Indigo You are given a program that takes the number as input. Complete the program so that it will output to the console the theme according to input number. Sample Input 2 Sample Output Dark