Question



Question 9 4 pts If the derived class class Doverrides a public member function functionName of the base class class, then to
> Question 11 4 pts In a function template, a generic data type starts with the key word name that stands for the data type.
Question 12 4 pts What is the value of x after the following statements execute? int x 25; int *p; PX *p - 84; NULL 0 25 84 D
0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer 9) (B) classB::functioName();

In order to call the base class function we use base class name becuase the derived class has overridden this function. So, in order to avoid ambiguity we use base class name with :: to call base class function.

Answer 11) (B) class

A function template declaration is:

template <class T> T anyFunctio(T arg){

}

Here generic data type keyword is class followed by T that can accept different data types such as int,float and so on.

Answre 12) (D) 84

p= &x. Here p gets the address of x variable. Now then *p = 84. The *p represent the value at address p and here we change it to 84. Thus the value of x changes to 84.

Answer 13) (B) catch(...) {   }

This statement will capture every exception

Add a comment
Know the answer?
Add Answer to:
Question 9 4 pts If the derived class class Doverrides a public member function functionName of...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • In a function template, a generic data type starts with the key word _____ followed by...

    In a function template, a generic data type starts with the key word _____ followed by a parameter name that stands for the data type. template class T function Which of the following blocks is designed to catch any type of exception? catch(){ } catch(...){ } catch(*){ } catch(exception){ } A friend function can only be a regular stand-alone function and can not be a member of another class. True False A function template is an actual function that the...

  • If the derived class overrides a public member function of the base class, then to specify...

    If the derived class overrides a public member function of the base class, then to specify a call to that public member function of the base class you use the name of the base class, followed by the ____ operator, followed by the function name with the appropriate parameter list. Question 16 options: 1) : 2) . 3) :: 4) $

  • Question 14 4 pts Which of the following is the general syntax of the function prototype...

    Question 14 4 pts Which of the following is the general syntax of the function prototype to overload the post-increment operator as a member function? className operator++ 0); friend className operator++(); className operator++ (int): friend className operator ++ (int); Question 15 4 pts Which of the following is a built-in operation on classes? increment assignment decrement relational Question 16 4 pts A friend function can only be a regular stand-alone function and can not be a member of another class....

  • Write a full class definition for a class named Player , and containing the following members: A data member name of t...

    Write a full class definition for a class named Player , and containing the following members: A data member name of type string . A data member score of type int . A member function called setName that accepts a parameter and assigns it to name . The function returns no value. A member function called setScore that accepts a parameter and assigns it to score . The function returns no value. A member function called getName that accepts no...

  • TreeNode.java public class TreeNode {    public int key;    public TreeNode p;    public TreeNode...

    TreeNode.java public class TreeNode {    public int key;    public TreeNode p;    public TreeNode left;    public TreeNode right;       public TreeNode () {        p = left = right = null;    }       public TreeNode (int k) {        key = k;        p = left = right = null;    } } BinarySearchTree.java public class BinarySearchTree {    public TreeNode root;       public BinarySearchTree () {        root...

  • In Java Which of the following statements declares Salaried as a subclass of payType? Public class...

    In Java Which of the following statements declares Salaried as a subclass of payType? Public class Salaried implements PayType Public class Salaried derivedFrom(payType) Public class PayType derives Salaried Public class Salaried extends PayType If a method in a subclass has the same signature as a method in the superclass, the subclass method overrides the superclass method. False True When a subclass overloads a superclass method………. Only the subclass method may be called with a subclass object Only the superclass method...

  • D Question 18 4 pts A function template is an actual function that the compiler uses...

    D Question 18 4 pts A function template is an actual function that the compiler uses to generate one or more functions. True False D Question 19 4 pts Calls to methods use the class identifier instead of the object identifier as the method qualifier. constructor friend static this Question 20 4 pts If inheritance is private, all members of the base class, including private members, become private members of the derived class. True False Question 21 4 pts is...

  • Question 1 2 pts The preprocessor executes after the compiler. False True Question 2 2 pts...

    Question 1 2 pts The preprocessor executes after the compiler. False True Question 2 2 pts What code is human-readable and follows the standards of a programming language? Secret code Source code Key code None of these Machine code Question 3 2 pts What is the symbol that marks the beginning of a one line comment? Question 1 2 pts The preprocessor executes after the compiler. True False Question 5 2 pts A statement that may be used to stop...

  • PROGRAMMING PROJECTS Implement the class umapHash Key, which creates a hash function for miniPair...

    Data Structure in C++ please type the code and the output. thanks PROGRAMMING PROJECTS Implement the class umapHash Key, which creates a hash function for miniPair ob- iects that uses only the key of the pair (first). The third template argument is a func- tion object type that takes a Key argument. Place the class in the header file "umaphash.h" 37. (a) // a hash function object type that applies KeyHashFunc // to the key in a miniPair object template...

  • Question 1 10 pts Inheritance is a capability of C++ to represent increased specialization that is...

    Question 1 10 pts Inheritance is a capability of C++ to represent increased specialization that is often found in real world relationships. True False Question 2 10 pts Inheritance between a child and parent object exhibits an 'relationship. Question 3 10 pts As you move down an inheritance relationship from parent to child, you typically move from a general to specific description. True False Question 4 10 pts The syntax for declaring DerivedClass to publicly inherit from BaseClass is given...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT