I am creating a function called show_magicians() that prints out the content of a list called magician_names.
I am trying to create a new function called make_great() that will modify the list magician_names into saying "The Great [Insert name]".
However I can only get it to print out "The Great Nick" and I am not sure how to modify this list so that when I call show_magicians, the function will print out the modified list.
For example:
magician_names = ['jim', 'kaitlyn', 'nick', 'paul', 'kyle']
After make_great function:
magician_names = ['The Great jim', 'The Great kaitlyn', 'The Great nick', 'The Great paul', 'The Great kyle']
Below is the code I have so far:
def show_magicians(magician_names):
for magician_name in magician_names:
print(magician_name.title())
magician_names = ['jim', 'kaitlyn', 'nick', 'paul', 'kyle']
show_magicians(magician_names)
def make_great(magician_names):
for magician_name in magician_names:
print("The Great " + magician_name)
make_great(magician_names)
ctrl+kto indent it. This way it will be readable