const char *

Go down

const char *

Post by Maithreyi on Wed Mar 24, 2010 12:03 pm

Can somebody differentiate char* const and const char* ?

Maithreyi

Posts : 76
Points : 142
Join date : 2010-03-03
Age : 30
Location : Haldia

View user profile

Back to top Go down

Re: const char *

Post by Mahee on Wed Mar 24, 2010 7:19 pm

char* const c -> "Pointer c" is constant
pointer value is constant and you cant change it
const char* c -> pointer to a "constant string c"
the string is constant and you cant change it
avatar
Mahee

Posts : 29
Points : 233
Join date : 2010-03-03
Location : Haldia

View user profile

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum