GkSeries.com

C++ Objective Questions & Answers | C Plus Plus Programming Language Quiz

13. Which of the following is not an arithmetic operator?
  • [A] +
  • [B} *
  • [C} -
  • [A] &

Answer: Option [D]

14. Which of the following is a correct comment?
  • [A] */ Comments */.
  • [B} ** Comment **.
  • [C} /* Comment */.
  • [A] { Comment }.

Answer: Option [C]

DOWNLOAD CURRENT AFFAIRS PDF FROM APP

15. When following piece of code is executed, what happens? b = 3; a = b++;
  • [A] a contains 3 and b contains 4.
  • [B} a contains 4 and b contains 4.
  • [C} a contains 4 and b contains 3.
  • [A] a contains 3 and b contains 3.

Answer: Option [A]

16. The parameters specified in the function call are known as ____________ parameters
  • [A] formal
  • [B} actual
  • [C} value
  • [A] original

Answer: Option [B]

17. Which of the following will not return a value?
  • [A] null
  • [B} void
  • [C} empty
  • [A] free

Answer: Option [B]

18. Function overloading is also similar to which of the following
  • [A] operator overloading
  • [B} constructor overloading
  • [C} destructor overloading
  • [A] none of the mentioned

Answer: Option [B]

19. _______ function has access to all private and protected members of the class for which it is a friend
  • [A] Friend
  • [B} Member
  • [C} Nonmember
  • [A] Void

Answer: Option [A]

20. Which is not a loop structure?
  • [A] for
  • [B} do while.
  • [C} while
  • [A] repeat until.

Answer: Option [D]

21. Which one of the following is a built in function?
  • [A] stringlen()
  • [B} strlength().
  • [C} strlen().
  • [A] strleng().

Answer: Option [C]

22. ________ is the process of using the same name for two or more functions
  • [A] Function overloading.
  • [B} Operator overloading.
  • [C} Default function.
  • [A] Default function. Constructors.

Answer: Option [A]

23. ___________ is used to write a single character to output file.
  • [A] cin().
  • [B} put().
  • [C} get().
  • [A] getw().

Answer: Option [B]

24. he technique of building new classes from existing classes is called _______.
  • [A] inheritance
  • [B} overloading
  • [C} constructor
  • [A] polymorphism

Answer: Option [A]

Please share this page

Click Here to Read more questions

Teacher Eligibility Test