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

What is the difference between a template and a macro?

1111


What is the function of I/O library in C++ ?

1268


What is difference between n and endl in c++?

1140


Write about all the implicit member functions of a class?

1118


What is the difference between global int and static int declaration?

1147


What is the maximum combined length of command line arguments including the space between adjacent arguments?

1035


What are the differences between new and malloc?

1197


Does there exist any way to make the command line arguments available to other functions without passing them as arguments to the function?

1290


What is the maximum value of a unsigned char a) 255 b) 256 c) 128

1118


Is c++ primer good for beginners?

1082


When should overload new operator on a global basis or a class basis?

1130


What is std namespace in c++?

1227


What is the use of pointer in c++ with example?

1081


What is operator overloading in c++ example?

1177


What is general format for a prototype?

1090