Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python Introducing Lists Using Lists Continental

I don't understand what wrong

Hi,

Please explain why i have the following error :

Bummer : there were 2 problems with your code, check the preview pane for more information.

Same error message if i try this :

for continent in continents: print("* " + continents[0,1])

Thanks

continents.py
continents = ['Asia', 'South America', 'North America', 'Africa', 'Europe', 'Antarctica', 'Australia']
# Your code here
for continent in continents:
    print("* " + continents(0))
    print("* " + continents(1))
grant Mitchell
grant Mitchell
6,919 Points

you cant use 0 like that, i believe your telling it to find the "0"

1 Answer

Hi, I try to Print a bulleted list of each continent from the continents list.

Output should look similar to:

  • Asia
  • South America