Answer Posted / devi
The above ans is also right.
->Friend function is the one that can access the private
data members of the same class and other class which it is
made as friend.
->The advantageous of friend function that function not called
by object of the class.
->That means without using object name and dot operator that call the friend function.It
can define private area and public area.
->The friend function define outside the class without using
the class name and scope resolution operator.
| Is This Answer Correct ? | 16 Yes | 7 No |
Post New Answer View All Answers
which feature are not hold visual basic of oop?
What are objects in oop?
What are properties in oop?
What is and I oop mean?
What is interface? When and where is it used?
what type of questions
What is constructor in oop?
Why do we use polymorphism in oops?
What is an advantage of polymorphism?
Why is object oriented programming so hard?
Why is oop useful?
What is destructor give example?
What is Difference Between Inheritance and creating object and getting data? means Class A extends B{ B.getMethod();} (OR) Class A{ b obj=new B(); obj.getMethod(); }
Question: Implement a base class Appointment and derived classes Onetime, Daily, Weekly, and Monthly. An appointment has a description (for example, “see the dentist”) and a date and time. Write a virtual function occurs_on(int year, int month, int day) that checks whether the appointment occurs on that date. For example, for a monthly appointment, you must check whether the day of the month matches. Then fill a vector of Appointment* with a mixture of appointments. Have the user enter a date and print out all appointments that happen on that date.
How can you overcome the diamond problem in inheritance?