constant variable
say
const int a=10;
then u cant change a to any other value... ie.,
a=11; would be an error..

constant pointer

int i=10,j;
int *const a=&i;
then that pointer is a constant pointer to that memory location..so that pointer can't be used to point to other location...
a=&j; //would be an error

pointer to a constant

int i=10;
const int *p=&i;
then the value pointed to by the pointer cant be changed.
*p=11; would be an error..
shabbir like this