Stream example code. Download both files. - stream_ex1.cpp, numbers.txt
Stream quiz - stream_quiz1.cpp
Arguments example code - arguments_ex1.cpp
The following problems are from the textbook chapter 9
Write C++ code to open a file with the name Hello.txt, store the message "Hello, World!" in the file, and close the file. Then open the same file again and read the message into a string variable. Close the file again.
Write a program that asks the user for a file name and displays the number of characters, words, and lines in that file. Then have the program ask for the name of the next file. When the use enters a file that doesn't exist (such as the empty string), the program should exit.
Now encrypt the letters as follows:
Write a program that encrypts or decrypts a file using this cipher. For example,
./crypt -d -kFEATHER encrypt.txt output.txt
decrypts a file using the keyword FEATHER. It is an error not to supply a keyword.