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 trial

C# C# Basics (Retired) Console I/O Console I/O

I dont know what to do!!!

I really dont know what this means!!!

CodeChallenge.cs
string bookTitle = "Ability Mindscape";
System.Console.Write("Enter a book title: ");

2 Answers

Carlos Federico Puebla Larregle
Carlos Federico Puebla Larregle
21,073 Points

First you create a variable called "bookTitle", second you assign a value to it (a string value in this case), third you are going to prompt to the console a message asking for a "book". Finally you are going to use the "ReadLine()" function so you can "catch" the user's input.

string bookTitle = "Ability Mindscape";
System.Console.Write("Enter a book title: ");
bookTitle = System.Console.ReadLine();

I hope that helps a little bit

Adrian Reszka
Adrian Reszka
4,555 Points

to put it in to steps . 1 step (1 line) : Create variable named bookTitle of type string and assign a text string of "Ability Mindscape" to this variable.

2 step (2 line) : System.Consol.Write - its basicly a method taken from c# libary, treat is as a keyword used to print somthing in the console. the thing in the "()" is the value that will be printed.

;)