You are on page 1of 3

Console Application

Time Limit: 3hrs

Multiple Choice Questions:

In this Section support your answer with appropriate choice: Give reasoning too?

1) Concatenating with strings are done with:


a) reserved words
b) method calls
c) operator overloading
d) operator overloading and method calls

2) In order for a class to use an interface, it must


a) Inherit the properties of interface.
b) Contain the same method as the interface
c) Creates an interface object.
d) a and b.
e) All of above.

3) Every class directly or indirectly extends the______class.

a) System
b) Object
c) Drawing
d) Console

4) what is property?
5) using System;
class _hello
{
static void Main( )
{
int x = 10;
int y;
y = x++;
int z = x > y ? x : y;
Console.WriteLine("output: {0}, {1},{2}", x,y,z);
}
}

a) output: 10, 10,10


b) output: 11, 10,10
c) output: 11,10,11
d) none

6) using system;
class _R4R
{
static void Main( )
{

Console.WriteLine("R4R");

}
}

a) No output.
b) Compile time error.
c) Runtime error.
d) None of above.

7) Are private class-level variables inherited?


a) Yes
b) No.
c) Using Base Keyword.
d) None of these.
8) Can you inherit multiple interfaces?
a) Yes
b) No
c) through Multicast Delegates
d) None of these.
9) What is the top .NET class that everything is derived from?
a)Using System.Object;
b)Using System.Object.net;
c)Using System.Library;
d)Using System.Collection.Generics;
10) Can You store multiple data type in Array?
a) Yes
b) No
c) using Jagged Array
d) None of these.
SECTION B
Subjective Type Questions

1) What is Boxing and UnBoxing in C#?


2) WAP using call by value and call by reference?Explain Briefly?
3) Why can’t you specify the accessibility modifier for methods inside the interface?
4) Can you declare the override method static while the original method is non-static?
How?
5) What’s the difference between an interface and abstract class?
6) Describe the accessibility modifier “protected internal”. ?
7) What is Abstract Class? When do you absolutely have to declare class abstract?
8) What is Virtual Method? Is it possible to override Private Virtual Methods?
9) Explain Access Modifiers of Class?
10) Can you allow class to be inherited, but prevent the method from being over-ridden?
11) What are Arrays? Explain Types of Arrays?
12) What is Overriding and Overloading?
13) What is the difference between this and base keyword?
14) What is Dot Net Framework, write different versions?
Section C

1) Split the String :

String str =”1, 2|3, 4| 5, 6”;

Where x=1, x=3, x=5 and y=2, y=4, y=6

2) Matrix Multiplication of Two Dimensional Arrays? Explain various methods of Array Lists?

3) WAP on C# to implement Multiple Inheritance?

4) What is Polymorphism and Method Overloading? WAP for it?

5) WAP for Multiplication of Jagged Array?

You might also like