Home » C# MCQ Questions with Answer

C# MCQ Questions with Answer

Are you preparing for a C# programming exam? If so, practicing with multiple choice questions (MCQs) can be a great way to test your knowledge and identify any areas where you need to brush up. In this blog post, we’ve compiled a list of C# MCQs with answers to help you study and succeed on your upcoming exam. Whether you’re a beginner looking to get started with C# or an experienced programmer looking to refresh your skills, these questions will provide a helpful and challenging review of the key concepts in the C# language. So, let’s dive in and see how much you know about C#!

C Sharp MCQ Questions and Answers:

Below are the multiple choice questions for the C# programming language, which is an object-oriented language developed by Microsoft and used to build a variety of applications, including web, mobile, desktop, and games.

Q1. Which of the following utilities can be used to compile managed assemblies into processor-specific native code?

  1. gacutil
  2. ngen
  3. sn
  4. dumpbin

2. ngen


Q2. Which of the following are value types?

  1. Integer
  2. Array
  3. Single
  4. Long

1. Integer

3. Single

4. Long


Q3. Which of the following statements is correct about Managed Code?

  1. Managed code is the code that is compiled by the JIT compilers
  2. Managed code is the code where resources are Garbage Collected.
  3. Managed code is the code that runs on top of Windows.
  4. Managed code is the code that is written to target the services of the CLR

4. Managed code is the code that is written to target the services of the CLR


Q4. Which of the following is the root of the .NET type hierarchy?

  1. System.Object
  2. System.Type
  3. System.Base
  4. System.Parent

1. System.Object


Q5. Which of the following CANNOT be used as an underlying datatype for an ‘enum’ in C#.NET?

  1. byte
  2. short
  3. float
  4. int
You May Also Like :   JAVA MCQ Questions with Answer

3. float


Q6. Which of the following statements is correct about an ‘enum’ used in C#.NET?

  1. ‘enum’ is a reference type
  2. ‘enum’ is a value type.
  3. Whether it a value type or a reference type depends upon size.
  4. Whether it a value type or a reference type depends upon a Project Setting made in Visual Stiiclio.NET.

2. ‘enum’ is a value type.


Q7. Which of the following statements are correct about Attributes in C#.NET?

  1. On compiling a C#.NET program the attibutes applied are recorded in the metadata of the assembly.
  2. On compilation all the attribute’s tags are deleted from the program.
  3. An attribute can have parameters.
  4. The attributes applied can be read from an assembly using Reflection class.

1. On compiling a C#.NET program the attibutes applied are recorded in the metadata of the assembly.

3. An attribute can have parameters.

4. The attributes applied can be read from an assembly using Reflection class.


Q8. Which of the following is absolutely necessary to use a class ‘Point’ present in namespace ‘Graph’ stored in library?

  1. Use fully qualified name of the ‘Point’ class.
  2. Use using statement before using the ‘Point’ class.
  3. Add Reference of the library before using the ‘Point’ class.
  4. Use using statement before using the ‘Point’ class.

3. Add Reference of the library before using the ‘Point’ class.


Q9. How many values is a function capable of returning?

  1. 1
  2. 0
  3. Depends upon how many params arguments does it use.
  4. Depends upon how many ref arguments does it use.

1. 1


Q10. In an inheritance chain which of the following members of base class are accessible to the derived class members?

  1. static
  2. protected
  3. private
  4. public

2. protected

4. public


C# MCQ Quiz and Online Test:

These C# MCQ practice sets gives you the feeling of reality and a clue to the questions asked in the actual C# .net related exams. When you solve these MCQ questions practically, you come across many difficulties that give you an opportunity to improve.

4.5/5 - (22 votes)
Scroll to Top