#include<stdio.h>
int main ()
{
char *s="FIGHT" ;
printf("\n Whole string is %s ", s ); // Printing FIGHT -- this is fine
s[0]='L' ;
printf ("\n Now whole string is %s", s ); // Printing LIGHT -- My Question is how string literal constant is getting modified when it is being stored in read only memory .
}
Above Code is working fine on my system.