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 trialSiyuan Welch
3,025 PointsExcellent! Now I need you to add a new variable named total. Then assign total to the sum of current_count and upcoming_
It seems like treehouse have a bug!
4 Answers
Ferdinand Pretorius
18,705 PointsIt fails because you are trying to delete the variable called "planned", however there is no such variable.
The code you need looks like this:
current_count = 14
planned = 5
upcoming_releases = 2
del planned
total = current_count + upcoming_releases
Hope this helps!
Ferdinand Pretorius
18,705 PointsI've just had a look and it seems fine.
The line reads as follow:
Excellent! Now I need you to add a new variable named total. Then assign total to the sum of current_count and upcoming_releases. I'd like you to use the variables, but if you just need to use the numbers, that's OK.
Siyuan Welch
3,025 PointsThis is my code but can not pass, can you tell me why please current_count = 14 del planned = 5 upcoming_releases = 2 total = current_count + upcoming_releases
Siyuan Welch
3,025 PointsIt will give me this warn! Bummer! invalid syntax (delete.py, line 2)
Siyuan Welch
3,025 PointsThank you so much! It worked.
Ferdinand Pretorius
18,705 PointsYou're welcome, happy coding!
Christopher Kehl
18,180 PointsThis was throwing me off because is specifically says to declare a var. total = current_count + upcoming_releases works
Siyuan Welch
3,025 PointsSiyuan Welch
3,025 PointsThank you so much! It worked.