In the above code color is a string. Would it work? what is the correct syntax to output a string to screen?Code:cout << "String is "<< color;
In the above code color is a string. Would it work? what is the correct syntax to output a string to screen?Code:cout << "String is "<< color;
-------------------------------------------------------------------
There are 10 kinds of people in this world....Those who understand binary and those who don't
Try it out yourself and find out.
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)
That's a strange question.
Ofcourse if works, there are only like 1,000,000 tutorials and examples that do that!