Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the use of friend function?

Answer Posted / vijaya

Sometimes a function is best shared among a number of
different classes. Such functions can be declared either as
member functions of one class or as global functions. In
either case they can be set to be friends of other classes,
by using a friend specifier in the class that is admitting
them. Such functions can use all attributes of the class
which names them as a friend, as if they were themselves
members of that class. A friend declaration is essentially a
prototype for a member function, but instead of requiring an
implementation with the name of that class
attached by the double colon syntax, a global function or
member function of another class provides the match.

Is This Answer Correct ?    90 Yes 15 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we extend multiple classes in php?

980


What are the encryption functions in php?

1067


What is api laravel?

1023


How does php session work?

906


What is die in php?

977


What is boolean in php?

935


How to invoke a user function?

930


How can you associate a variable with a session?

964


Swap two variables value without using third variable in php ?

1005


What is $_ env in php?

945


Where do I run php code?

915


Can we use onclick in submit button?

966


Explain mixed and callback functions?

1031


How can we display information of a variable and readable by human with php?

1017


Which operator is used to combine string values in php?

881