-
-
What is the .NET datatype that allows the retrieval of data by a unique key?
HashTable. What is class SortedList underneath?
-
How is the DLL Hell problem solved in .NET?
Assembly versioning allows the application to specify not only the library it needs to run (which was available under Win32), but also the version of the assembly.
-
How do you generate documentation from the C# file commented properly with a command-line compiler?
Compile it with a /doc switch.
-
What does assert() do?
In debug compilation, assert takes in a Boolean condition as a parameter, and shows the error dialog if the condition is false. The program proceeds without any interruption if the condition is true.
-
What are the ways to deploy an assembly?
An MSI installer, a CAB archive, and XCOPY command.
-
Is there regular expression (regex) support available to C# developers?
Yes. The .NET class libraries provide support for regular expressions. Look at the documentation for the System.Text.RegularExpressions namespace.
-
All the variables local to a method in C# must be initialized before they can be used
Skill/Topic: BeginnerA) TrueB) False
-
What is JIT?
Skill/Topic: IntermediateA) Java Internal TranslatorB) Just in TimeC) Just in Translation
-
Unsafe code in C# can be written in the flowing block:
Skill/Topic: AdvancedA) unsafe int ThisMethod(){}B) unsafe: int ThisMethod() { }C) int ThisMethod():unsafe { }
-
What does the keyword virtual mean in the method definition?
The method can be over-ridden.
-
How do you inherit from a class in C#?
Place a colon and then the name of the base class. Notice that it is double colon in C++.
-
What is a satellite assembly?
When you write a multilingual or multi-cultural application in .NET, and want to distribute the core application separately from the localized modules, the localized assemblies that modify the core application are called satellite assemblies.
-
What is a pre-requisite for connection pooling?
Multiple processes must agree that they will share the same connection, where every parameter is the same,
-
The compiler throws an error if XML comments is not well formed
A) TrueB) False
-
Can static methods be overridable?
A) YesB) NoC) It depends on how we declare themExplanation: Static methods cannot be overridable
-
What is the extension of a resource file
A) .csB) .rsxC) .resx
-
Which utility is used to create resource file
A) regasmB) resgenC) regsvrExplanation: Resgen.exe is used to create resource files in C#.net
-
Application Isolation is assured using
A) ThreadsB) RemotingC) ApplicationDomain
-
Windows services created by C# app run only
A) Windows 95B) Windows 98C) Windows NT & Above
C# Interview Questions
Ans