Employers - Post Free Jobs
Forum guidelines
AuthorQuestion
C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 23 Nov 2010
CAN ANYONE SOLVE MY 25 MCQ???
1. Question:

The global assembly cache:
 
a.     Can store two dll files with the same name
 
b.     Can store two dll files with the same name, but different version
 
c.     Can store two dll files with the same name and same version
 
d.     Can not store dll files with the same name


2. Question:
Which of the following statements is correct with regard to .NET framework managed web pages?

 
a.     They interact directly with the runtime
 
b.     They do not execute in the native code language
 
c.     They are interpreted and scripted
 
d.     All of the above


3. Question:

A banking application is online. As soon as Martin finished his session, Lisa logged on and did some banking. The connection string created for each of them is as follows:

String ConnStr=    "Server=BankServer;Database=BankDB;User=Martin;Password=gilbo123;"

String ConnStr=    "Server=BankServer;Database=BankDB;User=Lisa;Password=kari75;"

Which of the following statements will be correct in case the connection pooling is also switched on?

 
a.     There is a possibility of Lisa using the same connection object as created for Martin from the connection pool
 
b.     Lisa can not use someone else's connection from the connection pool
 
c.     Lisa can pick any other ideal connection from the connection pool
 
d.     None of the above


4. Question:
What are the core components of the .Net framework data provider model?

 
a.     DataAdapter and DataReader
 
b.     Connection and Command
 
c.     DataAdapter, Connection, and Command
 
d.     DataAdapter, DataReader, Connection, and Command


5. Question:

Dot Net Framework consists of :

 
a.     Common language runtime
 
b.     Set of class libraries
 
c.     Common language runtime and set of class libraries


6.  Question:

_____________ helped overcome the DLL conflict (faced by the versions prior to .NET).

 
a.     CLR
 
b.     JIT
 
c.     CTS
 
d.     GAC
 
e.     Satellite Assemblies
 
f.     All of the above


7. Question:

Which of the following types of cursors is available with ADO.NET DataReader object?

 
a.     server-side, forward-only, and read-write cursor
 
b.     server-side, forward-only, and read-only cursor
 
c.     server-side, backward-only, and read-write cursor
 
d.     server-side, bidirectional, and read-only cursor


8. Question:

Which of the following does not constitute the benefits of CLR?

 
a.     Ability to use components developed in different language
 
b.     Garbage collection
 
c.     IDL (Interface Definition Language) use is promoted by restricting self describing objects
 
d.     Ability to compile once, and run on any CPU


9. Question:

Can you overload a function with the same number and types of arguments (parameters) but with a different return type?

 
a.     Yes
 
b.     No
 
c.     Yes, but only if function is static
 
d.     Yes, but only if function is virtual


10. Question:

Which of the following are true about constructors and member functions?

 
a.     A constructor can return values, but a member function cannot
 
b.     A member function can declare and define values, but a constructor cannot
 
c.     A member function can return values, but a constructor cannot
 
d.     All of the above



11. Question:

Which of the following are true about operator overloading?

     a.     *operator can be overloaded to perform division
     b.     **can be overloaded to perform ''to the power of''
     c.     If == (equality operator) is overloaded then C# rules enforce that!= (inequality operator ) also be overloaded
     d.     If the + operator is overloaded then += works automatically
     e.     In a class named MyClass the following syntax is correct to overload equality:
public static bool operator ==(MyClass obj)



12A. Question:

Which of the following statements are correct with regard to Polymorphism?

 
a.     Polymorphism is a process by which a class can exist in multiple forms
 
b.     Polymorphism is a process by which a class can exist in only two forms
 
c.     Polymorphism is a process by which objects of a reference type can display different behavior
 
d.     Polymorphism is a process by which different instances of the same class display different behavior
 
e.     Polymorphism allows old code in a class library to call new code written by a programmer that derives a class from a class in the class library
       

12B. Question:

___________ namespace is not defined in the .NET class library.

 
a.     System
 
b.     System.CodeDom
 
c.     System.IO
 
d.     System.Thread
 
e.     System.Text


13. Question:

How can an abstract function be declared?

 
a.     By equating it to 1
 
b.     By equating it to zero
 
c.     By using the virtual keyword
 
d.     By using the abstract keyword


14. Question:

Which object oriented concept is related to the derivation of a class based on another class?

 
a.     Encapsulation
 
b.     Polymorphism
 
c.     Data Hiding
 
d.     Inheritance
 
e.     Overloading


15. Question:

Which of the following help increase the code safety and stability?

 
a.     Inheritance
 
b.     Polymorphism
 
c.     Abstraction
 
d.     Encapsulation


16. Question:

Which of the following are not C# value types?

 
a.     long
 
b.     bool
 
c.     struct
 
d.     class
 
e.     string


17. Question:

What happens when the below code is executed?

abstract class Shape
{
  public abstract void draw();
}

class Rectangle: Shape
{
  public override void draw();
  //Some more member functions.....
}

class CCheck
{
  public static void Main()
  {
    Shape objShape;
  }
}

 
a.     The code will compile and run.
 
b.     Compile error for draw method will be encountered first
 
c.     Defining the body of the draw() method in class Rectangle would let the class compile.
 
d.     None of the above


18. Question:

You created a stored procedure to retrieve the following details for the given customer:

CustomerName, Address, PhoneNumber

Which of the following is an ideal choice to get the best performance?

 
a.     Return the result as dataset using data adapter
 
b.     Return the result as dataset using command object
 
c.     Return the result as three out parameters and command object
 
d.     All of the above



19. Question:
In C#, exception handling should be used.........

 
a.    to handle the occurrence of unusual or unanticipated program events
 
b.    to redirect the programs normal flow of control
 
c.    in cases of potential logic or user input errors
 
d.    in case of overflow of an array boundary


20. Question:

Which of the following has the lowest precedence?

 
a.    Bitwise operators
 
b.    Multiplication and Division
 
c.    Assignment operators
 
d.    Logical operators


21. Question:
Which of the following is capable of returning multiple rows and multiple columns from the database?

 
a.    ExecuteReader
 
b.    ExecuteXmlReader
 
c.    DataAdapter
 
d.    All of the above


22. Question:

Which of the following command types are provided by an oledb and sql provider?

 
a.    StoredProcedure,Text,Table
 
b.    StoredProcedure,Query,Table
 
c.    Procedure,Text,Table,Query
 
d.    Procedure,Query,Table


23. Question:
Which access specifier will you use to make base class members accessible in the derived class and not accessible for the rest of the program?

 
a.    public access specifier
 
b.    private access specifier
 
c.    protected access specifier
 
d.    static access specifier


24. Question:

Which of the following define the rules for .Net Languages?

 
a.    GAC
 
b.    CLS
 
c.    CLI
 
d.    CTS
 
e.    CLR
 
f.    JIT


25. Question:

Which of the following are true?

 
a.    Function overloading is an example of static polymorphism
 
b.    Operator overloading is an example of static polymorphism
 
c.    Function overloading is an example of dynamic polymorphism
 
d.    Operator overloading is an example of dynamic polymorphism
 
e.    Overriding virtual functions of the parent class in a derived class is an example of static polymorphism
 
f.    Overriding virtual functions of the parent class in a derived class is an example of dynamic polymorphism




Arif
AuthorReply
Re: C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 24 Nov 2010  

Nice questions....

If this post helped you, then tick the "Do you like this Answer" checkbox.
Re: C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 24 Nov 2010  
Any one from here can answer any of the questions?

Arif
Re: C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 21 Nov 2011  
Hy dear i have solved all these questions, if some one varify them then i will be happy, but kindly with detail explanation.



Q1.  -> b
Q2..  -> d
Q3..  -> b
Q4..  -> d
Q5..  -> c
Q6..  -> a
Q7..  -> d
Q8..  -> c
Q9..  -> b
Q10..  -> c
Q11..  -> d
Q12A..  -> c
Q12B..  -> e
Q13...  ->d
Q14..  -> d
Q15..  -> d
Q16..  -> c
Q17..  -> b
Q18..  -> a
Q19..  -> c
Q20..  -> c
Q21..  -> d
Q22..  -> d
Q23..  -> c
Q24..  -> e
Q25..  -> a

Re: C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 09 Jan 2013  
answers : Q1. -> b Q2.. -> d Q3.. -> b Q4.. -> d Q5.. -> c Q6.. -> a Q7.. ->( b ) Q8.. -> c Q9.. -> b Q10.. -> c Q11.. -> d Q12A.. -> c Q12B.. -> e Q13... ->d Q14.. -> d Q15.. -> d Q16.. -> (d,e) Q17.. -> (b,c) Q18.. -> ( c) Q19.. -> c Q20.. -> c Q21.. -> d Q22.. -> d Q23.. -> c Q24.. -> e Q25.. -> a
Re: C# .net Fundamental Answers Needed for 25 MCQ
Posted on: 26 Aug 2013  
You can find answers for these here:

http://itdevelopersjunction.com/ForumDesign.aspx

SPONSORED BY

Offshore Software and Database Development
MCN is your source for developing solutions involving websites, mobile apps, cloud-computing, databases, BI, back-end services and processes and client-server applications.