diff options
Diffstat (limited to 'reference/CPLUSPLUS/EXAMPLES/io1.cc')
-rw-r--r-- | reference/CPLUSPLUS/EXAMPLES/io1.cc | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/reference/CPLUSPLUS/EXAMPLES/io1.cc b/reference/CPLUSPLUS/EXAMPLES/io1.cc new file mode 100644 index 0000000..22f22dc --- /dev/null +++ b/reference/CPLUSPLUS/EXAMPLES/io1.cc @@ -0,0 +1,19 @@ +/************************************************************************ + * + * Purpose: + * Author: M J Leslie + * Date: 26-Oct-98 + * + ************************************************************************/ + + +#include <iostream.h> // cout, cin + +main() +{ + char buf[255]; + + cout << "Please enter a string ==> "; // O/P to STDOUT (screen). + cin >> buf; // I/P from STDIN (keyboard). + cout << "Entered string is " << buf << endl; +} |