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 Python Basics (2015) Logic in Python Conditional Value

Cameron Kjellerson
PLUS
Cameron Kjellerson
Courses Plus Student 426 Points

How is this wrong?

Its not right unless I add the age value but it wont let me.

conditions.py
admitted = None
if age > 13:
    admitted = True
else:
    admitted = False

1 Answer

Brandon Benefield
Brandon Benefield
7,739 Points

You are so close and this is something I struggled with when beginning. The question specifies if age is 13 OR more. Not just simply more than 13. Change your if statement to

if age >= 13:

Just to clarify, you need to add a = to your conditional statement. Now your statement reads If age is greater than or equal to 13... do logic