FUNCTION ONE: MAINO In this lab we will create three functions. The first will be called main. Main will simply be the first function executed and will call the other two funetions. It will take in no...


FUNCTION ONE: MAINO<br>In this lab we will create three functions. The first will be called<br>main. Main will simply be the first function executed and will<br>call the other two funetions. It will take in no arguments and<br>will only create an empty list and call the other two functions.<br>FUNCTION TWO: GETDATAO<br>Getdata() will take in a list and then prompt the user to enter a<br>song as a string in the format of song-band. You may assume<br>the user will correctly enter this data. These songs will be<br>appended to our list. The user can continue entering songs until<br>they enter

Extracted text: FUNCTION ONE: MAINO In this lab we will create three functions. The first will be called main. Main will simply be the first function executed and will call the other two funetions. It will take in no arguments and will only create an empty list and call the other two functions. FUNCTION TWO: GETDATAO Getdata() will take in a list and then prompt the user to enter a song as a string in the format of song-band. You may assume the user will correctly enter this data. These songs will be appended to our list. The user can continue entering songs until they enter "exit". FUNCTION THREE: PLAYRANDOMO PlayRandom() will take in a list. It will then generate a random number and use it as index to select a random song to print "Now Playing: RandomSongHere". SAMPLE OUTPUT Enter a song title and band (song-band) or exit to quit: I Found- Amber Run Enter a song title and band (song-band) or exit to quit: Bark At The Moon-Ozzy Osbourne Enter a song title and band (song-band) or exit to quit: Real World-Matchbox 20 Enter a song title and band (song-band) or exit to quit: The Beginning of the End-H.L.M. Enter a song title and band (song-band) or exit to quit: Noise- Nightwish Enter a song title and band (song-band) or exit to quit: Hevioso- The 69 Eyes Enter a song title and band (song-band) or exit to quit: Falls Apart-Hurt Enter a song title and band (song-band) or exit to quit: Sound of Winter-Bush Enter a song title and band (song-band) or exit to quit: Crooked Spoons-Otep Enter a song title and band (song-band) or exit to quit: Devil and the Deep Dark Occan-Nightwish Enter a song title and band (song-band) or exit to quit: exit Now Playing: The Beginning of the End-H.L.M.
Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here