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 trialkevin burns
2,570 Pointsplz what's wrong
I thought I the code right ... guess not...
years = 41
years * 365 = days
3 Answers
andren
28,558 PointsYou have the assignment the wrong way around. Remember than in programming the = symbol is not used to declare two things as equal, like it does in math, but to assign a value to something.
That means that to assign years * 365
to days
you have to have days
on the left side of the equals sign. Like this:
years = 41
days = years * 365
Afloarei Andrei
5,163 Pointsuse the variable first, then assign the value
kevin burns
2,570 Pointsthanks that worked!!