Comment on Tutorial - const Member Functions in C++ By Emiley J



Comment Added by : z

Comment Added at : 2010-05-09 12:02:17

Comment on Tutorial : const Member Functions in C++ By Emiley J
u said that const function cant change object.can they change a static member of object?
itry that.and it can change it!why?

class c{
static int d;
void f() const {d=0;} //!
}
int c::d;
...
it has no error


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. nice examlpe but u can make it more easy so that t
View Tutorial          By: lovely at 2009-02-25 07:08:18

2. Excellent information
View Tutorial          By: mahesh at 2014-10-18 06:07:35

3. Really nice tutorial for memset(), memcopy() and m
View Tutorial          By: Hitesh Kumar at 2012-09-03 09:16:32

4. very good site for qustion answer. I just spellbo
View Tutorial          By: Anindya Mitra at 2012-04-22 16:28:42

5. good
View Tutorial          By: saravanan at 2007-03-02 23:16:00

6. If you use comments you will have better idea abou
View Tutorial          By: Mohammed Homam at 2009-12-06 04:43:51

7. This will give the output check it out


View Tutorial          By: shruthi at 2013-01-18 06:00:08

8. VERY HELPFUL TO ME AND MY FRIENDS.
THANK YO

View Tutorial          By: mansi at 2009-12-23 00:35:43

9. There is another similar discussion on use of tern
View Tutorial          By: Syed Mamun Raihan at 2008-09-10 11:29:42

10. The code gives the following exception :-
<

View Tutorial          By: VIKRAM at 2007-03-11 22:56:16