Skip to content

Latest commit

 

History

History
12 lines (8 loc) · 413 Bytes

exercise.md

File metadata and controls

12 lines (8 loc) · 413 Bytes

Switch

Objectives

  1. Generate a number between 0 and 10 and using switch statement do the following:
    1. If it's 1 print "One is the loneliest number that you'll ever do"
    2. If it's 2 print "Two can be as bad as one. It's the loneliest number since the number one"
    3. For any other number print "Sorry, no mention of the number in the song"

Solution

Click here to view the solution.