Question: Problem Description You will read in an encoded message from a text file, then output the decoded message to another text file. Programming Exercise Here
Problem Description
You will read in an encoded message from a text file, then output the decoded message to another text file.
Programming Exercise
Here is the encoded message
Mrkq#6=49#Dpsolilhg#Eleoh#+DPS,#%Iru#Jrg#vr#^juhdwo|`#oryhg#dqg#ghduo|#sul}hg#wkh#zruog/#wkdw#Kh#^hyhq`#jdyh#Klv#^Rqh#dqg`#^d`rqo|#ehjrwwhq#Vrq/#vr#wkdw#zkrhyhu#eholhyhv#dqg#wuxvwv#lq#Klp#^dv#Vdylru`#vkdoo#qrw#shulvk/#exw#kdyh#hwhuqdo#olih1
Copy this text and save it to a text file.
Write a C++ program that does the following:
Creates a class called Paragraph. It will have one private member variable of type string.
Opens the text file and reads in the text and stores it in an instance of Paragraph.
Decode the message by subtracting 3 from the ASCII value for each character (For example, M becomes J, and # becomes a space character).
Store the decoded message in another instance of Paragraph.
Output the decoded message to another text file.
If this is done successfully, you will see an English, decoded message in the new text file.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
