It is well known that the C language can be modified by using const;
C language can be modified by
the pointer int main ()
{
//So to speak in C language A is a read-only constant. According to the theory we are not easy to modify//
const int a=10;
printf ("%x", &a); The constant A in the//c language can be addressed.
int *p=null;
p= (int *) &a; But can modify *p=11 by address
;
printf ("After%d Modified", a);
}
This is a can be modified;
But look at the following C + + inside the
and in C + +, it can be defined like this.
The C + + compiler puts him in the symbol table during compilation
//A is a true constant according to the above.
int const A = ten;
int const B = one;
The length is given down at compile time
// array [10+11]//inside must be a constant; C + + compiled with fixed length
//So this is OK, but in C language it can't be
int Array[a + b] = {0};
If the brother has an unreasonable explanation, you can leave a comment, because the younger brother is also new;