Welcome to the Treehouse Community
Looking to learn something new?
Marek Ostrowski11,726 Points
printg 2 fisr arguments from list using for in statement
Hi I have stucked in continents.py
I can not modify continents list I have to print only 2 first arguments using for in statement
continents = [ 'Asia', 'South America', 'North America', 'Africa', 'Europe', 'Antarctica', 'Australia', ] for cont in continents: print("* ",cont)
If by first two arguments you referring to:
Output should look similar to:
- South America
the first task wants you to print all continents. You are close but by including a space and comma in your print function you will end up with two spaces between the bullet and the continent name.
for cont in continents: print("* ",cont)
for cont in continents: print("*", cont)
Using the comma will add the needed single space