Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In C please!! The substitution cipher is a cryptographic method for encrypting text such that it becomes unreadable to a party without access to the

image text in transcribed

In C please!!

The substitution cipher is a cryptographic method for encrypting text such that it becomes unreadable to a party without access to the cryptographic key. The encryption and decryption operations are simple substitutions of one letter with another using a 1-1 map. As an example, a substitution key is nothing more than a permutation of the alphabet. As an example, a substitution cipher is described by the following rule Plaintext: abcdefghijklmnopqrsturwxyz (the entire alphabet) Substitution key: xrhnkesdfgowqjvlzaibptmycu (a permutation of the alphabet) During encryption, a becomes x,b becomes r,c becomes h, and so on. During decryption, the opposite rule is followed. That is, to recover the original text, x becomes a,r becomes b,h becomes c, and so on. Write a C program that decrypts a file named "encrypted.txt" and places the decryption output to a file called "decrypted.txt". The file "encrypted.txt is encrypted with the 1-1 substitution map given in file substitution.txt. Only alphabet letters (uppercase/lowercase) must be decrypted. The remaining characters (question marks, periods, etc.) must remain intact

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions