Home / CSE / Object Oriented Programming Using C++ :: Section 1

CSE :: Object Oriented Programming Using C++

  1. You can use C++ as a procedural, as well as an object-oriented, language

  2. A.
    True
    B.
    False

    View Answer

    Workspace

    Discuss Discuss in Forum


  3. A default catch block catches

  4. A.
    all thrown objects
    B.
    no thrown objects
    C.
    any thrown object that has not been caught by an earlier catch block
    D.
    all thrown objects that have been caught by an earlier catch block

    View Answer

    Workspace

    Discuss Discuss in Forum


  5. Adding a derived class to a base class requires fundamental changes to the base class

  6. A.
    True
    B.
    False

    View Answer

    Workspace

    Discuss Discuss in Forum


  7. Format flags may be combined using

  8. A.
    the bitwise OR operator (|)
    B.
    the logical OR operator (||)
    C.
    the bitwise AND operator (&)
    D.
    the logical AND operator (&&)

    View Answer

    Workspace

    Discuss Discuss in Forum


  9. The use of the break statement in a switch statement is

  10. A.
    optional
    B.
    compulsory
    C.
    not allowed. It gives an error message
    D.
    to check an error
    E.
    None of the above

    View Answer

    Workspace

    Discuss Discuss in Forum


  11. To expose a data member to the program, you must declare the data member in the _____ section of the class

  12. A.
    common
    B.
    exposed
    C.
    public
    D.
    unrestricted
    E.
    user

    View Answer

    Workspace

    Discuss Discuss in Forum


  13. Evaluate the following expression: 3 >6&&7>4

  14. A.
    True
    B.
    False

    View Answer

    Workspace

    Discuss Discuss in Forum


  15. Which of the following are valid characters for a numeric literal constant?

  16. A.
    a comma
    B.
    a dollar sign ($)
    C.
    a percent sign (%)
    D.
    a space
    E.
    None of the above

    View Answer

    Workspace

    Discuss Discuss in Forum


  17. A function that changes the state of the cout object is called a(n) _____

  18. A.
    member
    B.
    adjuster
    C.
    manipulator
    D.
    operator

    View Answer

    Workspace

    Discuss Discuss in Forum


  19. A C++ program contains a function with the header int function(double d, char c). Which of the following function headers could be used within the same program?

  20. A.
    char function(double d, char c)
    B.
    int function(int d, char c)
    C.
    both (a) and (b)
    D.
    neither (a) nor (b)

    View Answer

    Workspace

    Discuss Discuss in Forum