Question: WRITE THE CODE IN C++ Secret Codes! Create a program that will accept a message from the user and either encrypt ordecrypt it with the
WRITE THE CODE IN C++
| Secret Codes! Create a program that will accept a message from the user and either encrypt ordecrypt it with the following algorithms: To encrypt: get the character you wish to encrypt find the index of that character in the alphabet array add the shift offset to the index add the increment to the index "wrap around" the new index so the result is between 0 and 29 find the character at the new index To decrypt: get the character you wish to decrypt find the index of that character in the alphabet array subtract the shift offset from the index subtract the increment from the index "wrap around" the new index so the result is between 0 and 29 find the character at the new index repeat steps 1-6 for every shift offset The alphabet is The increment should be +3 per letter position. Here is a sample message. Who said it? f..yqjrnvrpuabefw.j,ddxgcndpxmsdehsomjkcydfygtd.rrp?dgstmvxmf.wo?jxgrneslzifrgzyqv.v |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
