Word

Could you please write a program that reads and writes a word. Thanks!
1
2
3
4
5
6
7
8
9
10
11
#include <iostream>
#include <string>

int main()
{
    std::string word ;
    std::cout << "enter a word: " ;
    std::cin >> word ;

    std::cout << "the word you entered is '" << word << "'\n" ;
}
Topic archived. No new replies allowed.