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 trialroseleen zhou
2,321 Pointsformatting output
use Console. WriteLine to print the contents of the firstName variable to the screen.
string firstName =
Console.ReadLine().ToString();
Console.WriteLine("Enter First Name")
firstName=Console.ReadLine();
Console.WriteLine("\n");
2 Answers
Antonio De Rose
20,885 Points// you have made the simple complex.
string firstName =
Console.ReadLine().ToString(); // no need to convert it to string.
Console.WriteLine("Enter First Name") // this was not a part of the challenge, please stick to the question only and only from treehouse, dont create yours own.
firstName=Console.ReadLine(); //not sure, why is this
Console.WriteLine("\n"); // no need to create a new line
string firstName = Console.ReadLine();
Console.WriteLine(firstName);
Console.WriteLine(firstName + " rocks!");
roseleen zhou
2,321 Pointsthanks