You want to print output (text) to the console and have the cursor move to the next line. You should use this.
Console.WriteLine("");
Which data type is used to store multiple characters (text) such as a name or email
string
I am converting a string into an int. How can I do this?
Convert.ToInt32(Console.ReadLine());
to create and utilize a variable in c#, you must do the following: ______ and ___________.
declare and initialize
Single line comments are created with which special characters?
two forward slashes
//
You want to read the user's input. You should use this...
Console.ReadLine();
I want to store a user's entered age, but I don't plan on doing math with this data. Which data type should I use?
string
I am going to Convert an entered string (text) into a double. How can I do this?
Convert.ToDouble(Console.ReadLine());
string firstName;
This is an example of _______ a variable of string data type named firstName
declaring
The following special characters are used for what?
/*
*/
multi-line comments
You want to write output (text) to the console, but you want the cursor to remain on the same line. You would use this...
Console.Write();
I want to store a user's entered age, but I plan on doing math with this number. What data type would be best?
int
Fix the syntax.
Convert.ToDouble(Console.WriteLine());
should be Console.ReadLine() in the parentheses
string firstName = "John";
this is an example of declaring and _______ a variable.
initializing
prompt them in the output
(provide an example such as For example, 7)
You want to hide the ending information when you run your code. You can use this...
Hitting any key will reveal it though.
Console.ReadKey();
I am going to store a user entered temperature in Fahrenheit. Which data type would be best?
double
Fix the syntax. (2 things are wrong)
Convert.ToInt31(Console.ReadLine()):
should be 32 instead of 31 and should end in semi-colon instead of a colon
string fruit = "banana";
fruit = "apple";
Console.WriteLine(fruit);
What is the output?
apple
I would like to create a new line without using a CWL. What escape sequence can I use?
\n for newline
I want to store a user's entered name in a variable: string name; How should I capture their input and store it in this variable?
name = Console.ReadLine();
I am storing a number that will have a decimal place. What data type could I use?
double
string food = "pizza";
Convert.ToInt32(food);
What is wrong?
can't turn the text into a number.
a local variable should follow this naming convention...
such as myVariable
camel-case
What symbol denotes termination of a statement.
semi-colon