String Output in C++

Level 124 keystrokes

Prints the string "Hello" with cout and ends the line with endl.

C++ code

// cout is the standard output stream (std::cout; the snippet assumes using namespace std)
// << sends "Hello" to the stream, then endl adds a newline and flushes the buffer
1cout << "Hello" << endl;

Output

Hello
Practice typing this code

Practice typing this code. Results are not recorded in the rankings.

Symbols in this code

The symbols you type in this C++ code and how often they appear.

  • <× 4
  • "× 2
  • ;× 1

More C++ examples at level 1

← C++ typing practice