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 trialRuben WhyDoILoseFocus
688 PointsWhat does it mean when Treehouse says Task 1 no longer passing.?
I don't understand why task #1 is no longer passing. Thanks in advance.
admitted = None
if age > 10:
admitted = True
print(admitted)
else age <= 15:
admitted = False
1 Answer
Alexander Davison
65,469 PointsThe else
clause shouldn't take a condition.
The else
clause automatically gets called if the if
condition's value isn't true.
It will just cause an error :)
Try removing the condition from the else
clause.
Good luck! ~alex
Jason Anello
Courses Plus Student 94,610 PointsJason Anello
Courses Plus Student 94,610 PointsHi Ruben,
That type of error usually means that you've made an error on your current task which is not letting task 1 pass anymore. In this case, Alexander pointed out the error. You can only have conditions with
if
andelif
Also, the condition for task 1 was supposed to be if the age is greater than or equal to 13.
Tagging Kenneth Love , task 1 is passing with the condition
age > 10