Hello, I'm doing an exercise from the python crash course and thought about using the import statement I read about earlier.
``
from guest_list import invitees
print(invitees)
output:
I would like to invite you to dinner Npc1.
I would like to invite you to dinner Npc2.
I would like to invite you to dinner Npc2.
['npc1', 'npc2', 'npc3']
This is the content of guest_list:
###Exercise 3-4. Guest List
invitees = ["npc1", "npc2", "npc3"]
msg1 = f"I would like to invite you to dinner {invitees[0].title()}."
print(msg1)
msg2 = f"I would like to invite you to dinner {invitees[1].title()}."
print(msg2)
msg3 = f"I would like to invite you to dinner {invitees[1].title()}."
print(msg3)
``