Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Python Introducing Lists Using Lists Continental

print a bullet list of each continent from the continents list.

I do not understand what they mean that the code is used from previous task.

continents.py
continents = [
    'Asia',
    'South America',
    'North America',
    'Africa',
    'Europe',
    'Antarctica',
    'Australia',
]
# Your code here

5 Answers

Hi Alana!

What they are saying doesn't apply to the first task. (You'll code that yourself - from scratch.)

But task 2 will build on what you coded in task 1 (and so on - if there is a task 3, it would build on the code from task 2, etc.)

I hope that helps.

Stay safe and happy coding!

I did't get past the first task. Do you know what video this questions come from so I can re-watch it? Is it a list literal i need to put in as the coded to bullet each continent?

Hi Again!

This is the related video:

https://teamtreehouse.com/library/iteration-2

Your code within the loop should be (something like)

    print("* " + continent)

And this would work, too:

    print("* {}".format(continent))

I find the first approach much easier to read, in this case, however.

And, of course, you will use that inside a for/in loop.

for continent in continents:

If you say that out loud it sounds like "for continent incontinence"!?! (LOL)

You: "So do you wear boxers or briefs?"

Me: "Depends." (Ba-dum bum - tsssssh!?!)

(LOL - OK I clearly have too much free time...)

I hope that helps.

Stay safe and happy coding!

What a nice way to start studying...thank you again for the link to the video and the advice.

Alana

Ok, I just tried to figure out the second part to this challenge - print continents ending in "A" and you can access characters in a string by index. My code: print [0] [3] [5] [6]. Do I need something to this effect print "Asia" [0]? Second code: print ("Asia [0]", "Africa [3]", "Antarctica [5]", "Austrailia [6]) It didn't work.

Alana