artificial-intelligence-mcqs - Set (1)

Correct Answer: Orange && Worng Answer: Red

1. Which type is best suited to represent the logical values ?

  • (A). Integer
  • (B). Boolean
  • (C). Character
  • (D). All of the above
  • View Answer

    Explanation: The data type best suited to represent logical values in C++ is the Boolean type.

    2. Is the size of character literal different in C and C++ ?

  • (A). Implementation defined
  • (B). Can’t say
  • (C). Yes they are different
  • (D). No they are not different
  • View Answer

    Explanation: Not Avilable

    3. Size of C++ objects are expressed in terms of multiples of the size of a _____ and the size of char is _____

  • (A). char, 1
  • (B). int, 1
  • (C). float, 8
  • (D). char, 4
  • View Answer

    Explanation: Not Avilable

    4. _____ have the return type void ?

  • (A). All function
  • (B). Constructors
  • (C). Destructors
  • (D). None
  • View Answer

    Explanation: Constructor creates an Object and Destructor destroys the object. They are not supposed to return anything, not even void.

    5. Which variable does equals in size with enum variable ?

  • (A). Int
  • (B). Float
  • (C). String
  • (D). None
  • View Answer

    Explanation: Not Avilable

    6. The constants are also called as :

  • (A). Const
  • (B). Preprocessor
  • (C). Literals
  • (D). None of above
  • View Answer

    Explanation: Not Avilable

    7. The decleration of structure is also called as ?

  • (A). Structure creator
  • (B). Structure signifier
  • (C). Structure specifier
  • (D). None of above
  • View Answer

    Explanation: Not Avilable

    8. Which operator is having the higest precedence ?

  • (A). Postfix
  • (B). Unary
  • (C). Shift
  • (D). Equality
  • View Answer

    Explanation: Not Avilable

    9. What type of comments does C++ support ?

  • (A). Single line
  • (B). Multi line
  • (C). Single and multiline
  • (D). None
  • View Answer

    Explanation: Not Avilable

    10. Which is more effective while calling the functions?

  • (A). Call by value
  • (B). Call by reference
  • (C). Call by pointer
  • (D). None
  • View Answer

    Explanation: Not Avilable

    11. How many minimum number of functions are needed to be presented in C++ ?

  • (A). 0
  • (B). 1
  • (C). 2
  • (D). 3
  • View Answer

    Explanation: Not Avilable

    12. Function overloading is also similar to which of the following ?

  • (A). Operator overloading
  • (B). Constructor overloading
  • (C). Destructor overloading
  • (D). None
  • View Answer

    Explanation: Not Avilable

    13. Overloaded function are

  • (A). Very long function that can hardly run
  • (B). One function containing another one or more functions inside it.
  • (C). Two or more functions within the same class with different features.
  • (D). None
  • View Answer

    Explanation: Not Avilable

    15. Which of these following members are not accessed by using direct member access operator ?

  • (A). Public
  • (B). Private
  • (C). Protected
  • (D). Both private and protected
  • View Answer

    Explanation: Not Avilable

    16. Pick the other name of operator function

  • (A). Function overloading
  • (B). Operator overloading
  • (C). Member overloading
  • (D). None
  • View Answer

    Explanation: Not Avilable

    17. What is most suitable for returning the logical errors in the program ?

  • (A). Use constructor and destructor
  • (B). Set a global error indicator
  • (C). Use break keyword
  • (D). None of the above
  • View Answer

    Explanation: Not Avilable

    18. Which of the following can derived class inherit ?

  • (A). Members
  • (B). Functions
  • (C). Both member and functions
  • (D). None of the above
  • View Answer

    Explanation: Not Avilable

    19. Which of the following advantages we lose by using multiple inheritance ?

  • (A). Dynamic binding
  • (B). Polymorphism
  • (C). Both (A) and (B)
  • (D). None
  • View Answer

    Explanation: Not Avilable

    20. What will initialize the list of arguments in stdarg.h header file ?

  • (A). va_list
  • (B). va_start
  • (C). va_arg
  • (D). None
  • View Answer

    Explanation: Not Avilable