Q
quadraticformula
I recently purchased Stephen Davis's book C++ For Dummies, and came
across a simple declaration that I don't understand the workings of.
About 1/5 way through the book I see
char* szString = "Randy";
I was under the impression that char* szString should make a pointer
variable called szString. So why is the value set to "Randy" when from
what I've learned it should be set to &someVariable (the location of
some variable). This is located in the pointers chapter in a section
called "Expanding pointer operations to a string" if that is any help.
Thank's in advance for your time and your help.
Keegan Hernandez
across a simple declaration that I don't understand the workings of.
About 1/5 way through the book I see
char* szString = "Randy";
I was under the impression that char* szString should make a pointer
variable called szString. So why is the value set to "Randy" when from
what I've learned it should be set to &someVariable (the location of
some variable). This is located in the pointers chapter in a section
called "Expanding pointer operations to a string" if that is any help.
Thank's in advance for your time and your help.
Keegan Hernandez