How is read-only memory implemented in C?

Viewed 21777

I heard that in C, if I do

char *s = "hello world". 

the "hello world" is actually stored in read-only memory.

I am not so clear about read-only memory. What is the explanation? Is that like a flag to the compiler that tells the compiler to do not write into that section?

7 Answers
Related