logo

CuriousTab

CuriousTab

Object Oriented Programming Using C++ problems


  • 1. The use of the break statement in a switch statement is

  • Options
  • A. optional
  • B. compulsory
  • C. not allowed. It gives an error message
  • D. to check an error
  • E. None of the above
  • Discuss
  • 2. You define a structure type globally because _____

  • Options
  • A. you save many lines of code by not rewriting an identical structure definition in each function that uses it
  • B. you will never change its definition
  • C. it is required in C++
  • D. All of the above
  • Discuss
  • 3. Paying attention to the important properties while ignoring inessential details is known as________

  • Options
  • A. selectiveness
  • B. polymorphism
  • C. abstraction
  • D. summarizing
  • Discuss
  • 4. To use either an input or output file, the program must include the _____ header file

  • Options
  • A. filestream.h
  • B. fstream.h
  • C. instream.h
  • D. inoutstream.h
  • E. iostream.h
  • Discuss
  • 5. To expose a data member to the program, you must declare the data member in the _____ section of the class

  • Options
  • A. common
  • B. exposed
  • C. public
  • D. unrestricted
  • E. user
  • Discuss
  • 6. An array name is a _____

  • Options
  • A. subscript
  • B. formal parameter
  • C. memory address
  • D. prototype
  • Discuss
  • 7. Format flags may be combined using

  • Options
  • A. the bitwise OR operator (|)
  • B. the logical OR operator (||)
  • C. the bitwise AND operator (&)
  • D. the logical AND operator (&&)
  • Discuss
  • 8. Adding a derived class to a base class requires fundamental changes to the base class

  • Options
  • A. True
  • B. False
  • Discuss
  • 9. You can use C++ as a procedural, as well as an object-oriented, language

  • Options
  • A. True
  • B. False
  • Discuss
  • 10. If container classes are carefully constructed, then these tools are available to work with structures that are not ______

  • Options
  • A. valid without container classes
  • B. programmer-defined
  • C. type-specific
  • D. public
  • Discuss

First 2 3 4 5