Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
How come the value of last cout statement is
[blue] My sister's married name is name was [/blue]
char *c = "Bettye Lou Horn";
cout << "My sister's maiden name was" << c << "
c = c+11; // Make c point to the last name (the 12th character)
c = "Henderson";
c = c - 11; // Make c point to its original location.
cout << "My sister's married name is" << c << "
// when we use *c in cout statement only B prints why