Programming fundamentals in C#
A quiz that aims to check if you understand the basics of programming and Visual Studio.
A score of 30 points+ (out of 60 total) is needed to advance to the next chapter.
Sign in to Google to save your progress. Learn more
In order to declare a local variable you need to provide: *
2 points
Required
In order to use a local variable, it must have a value assigned explicitly. *
1 point
Required
Which of the following is invalid? *
3 points
Required
Which of the following are types for whole numbers? *
1 point
Required
Which of the following are types for numbers with a fraction? *
1 point
Required
var number = 4.0f // What type is number? *
1 point
Required
var number = 1 + 4.0f // What type is number? *
1 point
Required
var a = "a"; // what type is a? *
1 point
Required
Console.WriteLine("5 / 2"); // what does this print? *
1 point
Required
Console.WriteLine(5 / 2); // what does this print? *
1 point
Required
Console.WriteLine(5 / 2.0); // what does this print? *
1 point
What is git? *
1 point
Which of the following does not belong to git? *
3 points
Required
Which git command is involved for moving files from working directory to staging area? *
1 point
Which git command is involved for moving files from local to remote repository? *
1 point
Which git command is involved for moving files from staging area to local repository? *
1 point
Which command is used to move files to safe place locally for later working with them? *
1 point
When will merge conflict happen? *
1 point
Required
Every function must have a return statement. *
1 point
In order to declare a function you must give it: *
2 points
Required
You have the following piece of code. Refer to the 3 questions below and answer them.
Which of the following is true about Foo and Bar? *
2 points
Required
FooBar is invalid because: *
2 points
Required
What's wrong with function Sum? *
1 point
Which numbers will return true passed to IsValidNumber function? *
3 points
Captionless Image
Required
Which loop is the most appropriate for iterating over an array of numbers? INDEX DOES NOT MATTER *
2 points
Which loop is the most appropriate for iterating over an array of string? INDEX DOES MATTER *
2 points
Which of the following can stop the loop completely? *
2 points
Required
Which is not a valid way of declaring array in C#? *
2 points
What will be printed? *
2 points
Captionless Image
What will the output be? *
1 point
Captionless Image
What will the output be?
1 point
Captionless Image
Clear selection
What will the output be? *
1 point
Captionless Image
What is a breakpoint? *
1 point
While debugging in VS, how to go back to the line executed before?
1 point
Clear selection
What is a Watch? *
2 points
What is the purpose of an Immediate Window? *
2 points
Which best define a stream? *
1 point
File "C://Out.txt" does not exist. What happens if you do: File.WriteAllText("C://Out.txt", "Hello out!"); *
1 point
Which of the following is a way of generating a random number between 0.1 and 0.5 given Random random = new Random(); Note: Presume that all random signatures are correct. *
2 points
Required
Caesar cypher is based on which operation? *
1 point
What could be a reason of 😀 sign appearing as ? instead? *
2 points
Submit
Clear form
This content is neither created nor endorsed by Google. Report Abuse - Terms of Service - Privacy Policy