If necessary, create a new project named TryThis17 Project and save it in the Cpp8Chap14 folder. Also

Question:

If necessary, create a new project named TryThis17 Project and save it in the Cpp8\Chap14 folder. Also create a new source file named TryThis17.cpp. Write a program that saves records to a sequential access file named TryThis17.txt. Each record should appear on a separate line and contain two fields separated by the number sign (#). The first field should contain numbers from 10 through 25. The second field should contain the square of the number in the first field. For example, the first record will contain 10#100 followed by the newline character. Display the message “Numbers saved in file.” if the program was able to save the numbers. Save and then run the program. Verify that the program worked correctly by opening the TryThis17.txt file in a text editor. Close the TryThis17.txt file.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: