0

programming languages Online Quiz - 84

Description: programming languages Online Quiz - 84
Number of Questions: 20
Created by:
Tags: programming languages
Attempted 0/20 Correct 0 Score 0

LINQ query to Select and return all the rows from Product table and display the product names.

  1. Dim query = From product In products.AsEnumerable() Select product

  2. Dim query as select product From product In products.AsEnumerable()

  3. Dim query = From p In products.AsEnumerable() Select p

  4. None of these


Correct Option: A
  1. Commit();

  2. Update();

  3. SubmitChanges();

  4. CommitTransaction();


Correct Option: C
  1. SqlDataAdapter

  2. SqlConnection

  3. SqlDataReader

  4. SqlDataView


Correct Option: D

Which is/are the method/s of an ADO.NET command object

  1. CreateObjRef

  2. BeginExecuteNonQuery

  3. Prepare

  4. All of the above


Correct Option: D

Is the following statement correct: char ch = 'd'; if(ch < 32.00){ }

  1. True

  2. False


Correct Option: A

Is following line throws Exception.If yes ,which type? justify it . float f = 100.00/0.0

  1. True

  2. False


Correct Option: B

what is the output? class A{ int i=1; void printit() { i=i++; system.out.println(i);} } class AS { public static void main(String s[]) { A a=new A(); a.printit(); } }

  1. 1

  2. 2

  3. Error

  4. None


Correct Option: A

Which one is faster in java ? A. Math.max(a,b); B. (a>b)?a:b

  1. A

  2. B

  3. Both are Same

  4. None


Correct Option: B

Which of the following is(are) true for Macro functions(#define fn()) & inline functions

  1. macro functions are expanded during compile. Inline functions are just usual functions calls

  2. macro functions are expanded during preprocessing and inline functions are expanded during compile

  3. macro functions are expanded during compile and inline functions are expanded during preprocessing

  4. No difference.Both are expanded at compile.


Correct Option: B

What is abstract class?

  1. A class which can not be inherited

  2. A class which can have only single object

  3. A class which can not have any objects

  4. A class which can not inherit other classes


Correct Option: C

How is dynamic binding achieved in C++?

  1. Using virtual functions

  2. Using method overloading

  3. Using operator overloading

  4. Using both method & operator overloading


Correct Option: A
  1. constructors can be virtual

  2. destructors can be virtual

  3. constructors can be overloaded

  4. virtual functions are fast in execution


Correct Option: B,C
  1. all(d,si,i) in stack

  2. d in stack;si in heap;i in stack

  3. d in stack;si in stack;i in heap

  4. d in heap;si in heap;i in stack


Correct Option: B
  1. constructors are executed only(once) when the first object is instantiated

  2. destructor is executed only at the end of main() execution

  3. constructors are executed on every object instantiation

  4. destructor is executed when all the objects of the class moves out of scope

  5. constructors can not take parameters


Correct Option: C
  1. that can not be inherited

  2. that can be inherited only once

  3. that can have only one object

  4. there is no such class


Correct Option: C
  1. malloc is used to allocate store for integer arrays only

  2. new is used to allocate store for objects only

  3. new is used to allocate any kind of memory

  4. malloc is used to allocate any kind of memory

  5. new initializes the store after allocation

  6. malloc intializes the store after allocation


Correct Option: C,D
- Hide questions