I'm been working my way through my C++ book ("C++ Without Fear") for a second time. Something I've noticed is that in the example code, the guy often writes stuff like this:
When that kind of thing could be written using less code, like this:Code:cout << "Enter strings, separated by commas,"; cout << endl << "and press ENTER: ";
Is there a benefit to writing this kind of thing in the former way?Code:cout << "Enter strings, separated by commas," << endl << "and press ENTER: ";
Thanks.