I guessed no, but this output of something like this shows it does
string s=\"\";
cout<<&s;
what is the point of having empty string
Following your logic, int i;
would also not allocate any memory space, since you are not assigning any value to it. But how is it possible then, that this subsequent operation i = 10;
works after that?
When you declare a variable, you are actually allocating memory space of a certain size (depending on the variable's type) to store something. If you want to use this space right way or not is up to you, but the declaration of the variable is what triggers memory allocation for it.
Some coding practices say you shouldn't declare a variable until the moment you need to use it.