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 trialRasmus Andersen
1,569 Pointsproblem with "converting strings into integers" code challenge pls. help
I Have a problem with a code challenge
string heightInput = "168"; (and then i don't know what to write
Pls. help me or come up with your solutions
5 Answers
Murtaza H
8,735 Pointsuse it this way
string heightInput = "168"; int height = int.Parse(heightInput);
that should do it ...
anil rahman
7,786 Pointslink challenge
Rasmus Andersen
1,569 Pointsim new here so how do i do that
anil rahman
7,786 PointsString to int is normally something like this:
//declare new variable of int
//set equal to the method Int32.Parse
//then just pass in your string variable
int x = Int32.Parse(heightInput);
Murtaza H
8,735 Pointsint height = int.Parse(heightInput);
Tesfay Kidane
Courses Plus Student 7,500 Pointsint height = int.Parse(heightInput); or int height = Convert.ToInt32(heightInput);
anil rahman
7,786 Pointsanil rahman
7,786 PointsWhen you are stuck on quizzes or challenges there is a button next to the check work called get help if you ask from there it will link the challenge you are working on also. :)