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
Timo Baldwin
6,376 Pointshi, I can't get trough this task, what am i doing wrong. thanks. The else is wrong, why?
admitted = None
age = 15
if age >=13:
admitted = (true)
else:
admitted = (False)
Timo Baldwin
6,376 Pointsthanks jag, for directions ```py
1 Answer
akak
29,446 PointsI don't know which task are you referring but the code should look something like this:
admitted = None
age = 15
if age >=13:
admitted = True
else:
admitted = False
Watch out for indentation and you don't need to put True/False inside brackets when assigning to a variable.
Timo Baldwin
6,376 Pointsthanks akak
jag
18,266 Pointsjag
18,266 PointsYou can use three back ticks ( ` ) followed by py to use the code block.
# Python Code HereAlso I can't see what task you are referring to as you posted directly into the community.