Skip to content

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

16 Techno Beats

You are working with a DJ and he needs a program that can create a beats for his songs.

📝Instructions:

  1. Create a function called lyrics_generator that receives a list. The list passed to the function will be something like this:
    [0,0,1,1,0,0,0]
  1. For each Zero you will add to the string Boom.

  2. For each One you will add to the string Drop the base.

❕ In addition:

If you find the number 1 three times in a row, you should ALSO ADD to the string !!!Break the base!!!

💡 Hint:

  • Remember to use auxiliary variables.

  • Declare a variable to store

  • Declare a variable to count and sum

Expected result:

Boom Boom Drop the base Drop the base Boom Boom Boom
Boom Boom Drop the base Drop the base Drop the base !!!Break the base!!! Boom Boom Boom
Boom Boom Boom
Drop the base Boom Drop the base
Drop the base Drop the base Drop the base !!!Break the base!!!