" Write down a program which reads lines of
input from keyboard until you enter a blank line.
After reading the lines the program will tell how
many characters, words and sentences were there
in the input. "
#include <iostream>
#include <string>
int main()
{
std::string line ;
// read line by line from stdin until a blank line is entered
while( std::getline( std::cin, line ) && !line.empty() )
{
// process the line that was just read
// count characters etc.
}
}