C++ promotes the concept of inserting an object into a stream. For standard output this stream is
cout. Standard error is
cerr and there's also
clog though I haven't figured where that fits.
To send something to the stream you use the
<< operator.
char *text = "This is a stored string";
int value = 10000;
cout << "This is a string literal " << text << ' ' << value << endl;
This would send
This is a string literal This is a stored string 10000
to the standard out stream. The
endl at the end is an end line token, which generates a carriage-return/linefeed sequence.
There are other tokens that can be inserted to affect the formatting of the lines but that gets a bit involved and is beyond the scope of this class.
Lilith, Night Butterfly
I'm not a programmer but I play one in the office