Explore what CodeHS has to offer for districts, schools, and teachers.
Click on one of our programs below to get started coding in the sandbox!
View All
Which of the following best describes what the mystery procedure does?
mystery
Continuously prompts the user for a song and adds it to a list. Once the user enters Exit, the procedure returns the last song entered.
Exit
Prompts the user for a song and adds it to a list. The procedure then returns the song entered.
Continuously prompts the user for a song and adds it to a list. Once the user enters Exit,Exit is added to the list and the procedure returns the list of songs entered.
Continuously prompts the user for a song and adds it to a list. Once the user enters Exit, the procedure returns the list of songs entered.