-
A delegate in C# is similar to:
Skill/Topic: AdvancedA) COMB) a function pointerC) a pointer
-
What is a multicast delegate?
Skill/Topic: IntermediateA) a delegate having multiple handlers assigned to itB) a delegate called multiple timesC) a delegate which has multiple implementations
-
The correct syntax for defining a delefate is:
Skill/Topic: AdvancedA) delegate {MyMethod( int y) }B) delegate void MyMethod(int y) ;C) delegate: MyMethod (int y)
-
To write a line of text to the xonsole window, we make the following call
Skill/Topic: BeginnerA) Console.WriteLine()B) console.writeline()C) System.Output()
-
-
What is true about readonly variable in C# code?
Skill/Topic: BeginnerA) It's the same as a constantB) It's value can be assigned only onceC) You can never assign a value to it
-
Namespaces
When do you apply Namespace Alias Qualifiers and Extern Namespaces Alias?
-
IF a namespace isn't supplied, which namespace does a class belong to
Skill/Topic: IntermediateA) a nameless global namespaceB) SystemC) Windows
-
.NET FRAMEWORK
.NET FRAMEWORK1. What is .NET Framework?The .NET Framework has two main components: the common language runtime and the .NET Framework class library.You can think of the runtime as an agent that manages code at execution time, providing core services such as memory management, thread management, and remoting, while also enforcing strict type safety and other forms of code accuracy that ensure security...
-
Structs and classes support inheritance
Skill/Topic: IntermediateA) TrueB) FalseExplanation: Only classes can inherit. Structs can’t.
-
-
Namespaces are used to
Skill/Topic: IntermediateA) Separate assembliesB) Create a unique name for an assemblyC) Avoid name clashes between data types
-
Delegate
The following code illustrates a situation where a boss wants to keep track of the work progress of its subordinates: using System;namespace BigCompany { public class Boss { public void WorkerPercentageDone(int percentage) { Console.WriteLine("I am the boss, and my worker is " + percentage + "% done."); } } public class Worker { Boss boss = null; public Worker(Boss boss) ...
-
An assembly can be stored across multiple files?
Skill/Topic: IntermediateA) YesB) No
-
The field variables in a class or a struct in C# are by default given a value of zero
Skill/Topic: BeginnerA) TrueB) False
-
XML documents for a C# program can be generated using
Skill/Topic: IntermediateA) /xmldoc switchB) /doc switchC) /gendoc switch
-
Which of the following are predefined reference types in C#?
Skill/Topic: BeginnerA) intB) objectC) string
-
Delegates and Generics in c#
What is the advantage of using delegates and Generics in c# .
-
How do I make a DLL in C#?
You need to use the /target:library compiler option.
-
'this' in C#
Explain about 'this' and where and when it should be used?
C# Interview Questions
Ans