What is the output of Console.WriteLine(5 == 2) in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
False
Answer option 2
True
Answer option 3
5
English
Which of the following is a correct way to declare an indexer in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
public int this[int index] { get { return array[index]; } set { array[index] = value; } }
Answer option 2
public int this[int index] = { get { return array[index]; } set { array[index] = value; } }
Answer option 3
public int this[int index] => { get { return array[index]; } set { array[index] = value; } }
English
What is the purpose of the 'event' keyword in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
To declare an event that can be subscribed to by event handlers
Answer option 2
To declare a constant
Answer option 3
To declare a static field
English
What is the output of Console.WriteLine(5 <= 2) in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
False
Answer option 2
True
Answer option 3
5
English
What is the output of Console.WriteLine(5 >= 2) in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
True
Answer option 2
False
Answer option 3
5
English
Which of the following is a correct way to declare a lambda expression in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
x => x * x
Answer option 2
x -> x * x
Answer option 3
x => { return x * x; }
English
Which of the following is a correct way to declare a tuple in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
var tuple = (1, "Hello");
Answer option 2
var tuple = {1, "Hello"};
Answer option 3
var tuple = [1, "Hello"];
Reference Link
English
What is the output of Console.WriteLine(5 < 2) in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
False
Answer option 2
True
Answer option 3
5
English
Which of the following is a correct way to declare a dictionary in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
Dictionary<int, string> dict = new Dictionary<int, string>();
Answer option 2
Dictionary dict = new Dictionary();
Answer option 3
Dictionary<int, string> dict = new Dictionary();
English
Which of the following is a correct way to declare a list in C#?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
List<int> list = new List<int>();
Answer option 2
List list = new List();
Answer option 3
List<int> list = new List();
English