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...

How const functions will be treated by compiler?

Answer Posted / achal ubbott

A member function can be const qualified. e.g.

class SAAMPLE
{
int m1;
void f() const;

}
Now function f will not be able to modify the value of data
members. If so done the compiler would report an error.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is c++ a float?

1070


How many keywords are used in c++?

1021


Why isn't sizeof for a struct equal to the sum of sizeof of each member?

1000


What are member functions used in c++?

1152


Which c++ operator cannot overload?

1021


What is std :: flush?

1081


What does new return if there is insufficient memory to make your new object?

1040


What is wrapper class in c++?

1125


What is size of string in c++?

987


Should the member functions which are made public in the base class be hidden?

1034


What is array in c++ pdf?

1195


What are the various storage classes in C++?

1142


Tell me can a pure virtual function have an implementation?

1034


What is general format for a prototype?

1043


What is data types c++?

1023