C DATA TRANSMIT A company wants to transmit data over the te

C++

DATA TRANSMIT A company wants to transmit data over the telephone, but they are concerned that the phones may be tapped. All of their data are transmitted as four-digit integers. They have asked you to write a program that encrypts their data so that it can be transmitted more securely. Your program should read a four-digit integer (only one input) and encrypt it as follows: Replace each digit by (the sum of that digit plus 7 ) modulus 10. Then, swap the first digit with the third, swap the second digit with the fourth and print the encrypted integer. NOTE: Comments and Indentations must be included in this program and future programs, if not, points will be deducted. OUTPUT SAMPLE: Enter a four digit number : 4512 DIGITS 4 5 1 2 lst DIGIT Replacement using modulus 1 2 8 9 ENCRYPTED 8 9 1 2

Solution

Encrypted Code is :

Decrypted code is:

C++ DATA TRANSMIT A company wants to transmit data over the telephone, but they are concerned that the phones may be tapped. All of their data are transmitted a

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site