Tuesday, August 6, 2013

.NET MCQ Test – 3


 Que.1. Choose the correct one

A:        The return value of the lambda (if any) must be explicitly convertible to the delegate's return type
B:        Each input parameter in the lambda must be implicitly convertible to its corresponding delegate parameter.
C:        Lamda expression does not work with LINQ
D:        None of the above

Right Answer: B

Que.2. Choose the correct one

A:        Variables introduced within a lambda expression are not visible in the outer method.
B:        Variables introduced within a lambda expression are visible in the outer method.
C:        The lambda should not contain the same number of parameters as the delegate type.
D:        None of the above

Right Answer: A

Que.3. For building new types at runtime which class can be used

A:        System
B:        System.Object
C:        System.NewClass
D:        System.Reflection.Emit.

Right Answer: D

Que.4. A web application can contain

A:        Only One Web.Config File
B:        Only Two Web.Config File
C:        Can be more than ONE
D:        None of the above

Right Answer: C

Que.5. You have to log the data into database if your session times out.Which event you will use?

A:        Session_End
B:        Application_End
C:        Application_Start
D:        Application_SessionTimeout

Right Answer: A

Que.6. Choose the correct one

A:        Dynamic type is non static type
B:        Dynamic type is static type
C:        Implicit conversion does not work with type dynamic
D:        None

Right Answer: B

Que.7. Which SqlCommand execution return the number of effected records in the table?

A:        ExecuteNonQuery
B:        ExecuteReader
C:        ExecuteXmlReader
D:        ExecuteScalar

Right Answer: A

Que.8. If you are using Webparts in your web page then which control is necessary?

A:        WebpartController
B:        WebPartmanager
C:        WebpartZone
D:        None

Right Answer: B

Que.9. Choose the correct one

A:        The lambda must contain the same number of parameters as the delegate type.
B:        The lambda should not contain the same number of parameters as the delegate type.
C:        The return value of the lambda (if any) must be explicitly convertible to the delegate's return type
D:        None of the above

Right Answer: A

Que.10. What is lamda expression?
1.Anonymous function
2.Can be used to create delegates
3.Named function
4.None

A:        1, 2
B:        1,2,3
C:        1,3
D:        4

Right Answer: A

Que.11. How you can merge the results from two separate LINQ queries into a single result set.

A:        Use the ToList method.
B:        Use the DataContractJsonSerializer class.
C:        Use the XElement class.
D:        Use the Concat method.

Right Answer: D

Que.12. Which of the following is true when referencing master page from content page?

A:        Content pages can reference private indexer in the master page.
B:        Content pages can reference private Properties in the master page.
C:        Content pages can reference public Properties in the master page.
D:        Content pages can reference private Methods in the master page.

Right Answer: C

Que.13. Which of the following objects represents a LINQ to SQL O/R map?

A:        DataSet
B:        XElement
C:        ObjectContext
D:        DataContext

Right Answer: D

Que.14. Which data provider gives the maximum performance from a connection to SQL Server?

A:        The OLE DB data provider.
B:        The JDBC data provider.
C:        The SqlClient data provider.
D:        The Oracle data provider

Right Answer: C

Que.15. What component do you need to enable for a user to add new web parts ?

A:        WebpartZone
B:        CatalogZone
C:        WebPartManager
D:        WebManager

Right Answer: B

Que.16. Which CommandType value is incorrect?

A:        StoredProcedure
B:        TableDirect
C:        TableSchema
D:        Text

Right Answer: B

Que.17. Which SqlCommand execution return the value of the first column of the first row from a table?

A:        ExecuteNonQuery
B:        ExecuteReader
C:        ExecuteXmlReader
D:        ExecuteScalar

Right Answer: D

Que.18. LINQ query can work with?

A:        DataSet
B:        List< T>
C:        Array
D:        All of the above

Right Answer: D

Que.19. What is jQuery?
1.jQuery is an open source library
2.It works client side.
3.jQuery is java technology.
4.None

A:        1, 2
B:        1,2,3
C:        1,3
D:        4

Right Answer: A

Que.20. The best way for handling exception when dealing with a database connection?

A:        Implement a try/catch block that catches System.Exceptions.
B:        Implementing custom error page.
C:        Implement a try/catch block that catches individual exception types, such as SQLException.
D:        Display an error message.

Right Answer: A

No comments:

Post a Comment