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 trialscipiosean
627 PointsHelp don't know what did wrong
So I am just trying to see if the code runs before I do anything else because i just solved a problem I had but now when I run it it is telling me this error
Program.cs(33,52): error CS0103: The name `minutes' does not exist in the current context
I have a snapshot of the code here https://w.trhou.se/e3hsca6pyq
The one i am talking about is Program.cs
hope someone can help thanks!
1 Answer
Jennifer Nordell
Treehouse TeacherHi there! You simply have a typo. on line 31 to 33 you have this:
int Minutes = int.Parse(input);
runningTotal = runningTotal + minutes;
You declared a variable named Minutes
but then you try to use minutes
. Capitalization matters My advice? rewrite the declaration to:
int minutes = int.Parse(input);
Hope this helps!