Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

In c language please

image text in transcribed

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: abcdefghijklmnopqrstuvwxyz (the entire alphabet) Substitution key: xrhnkesdfgowqjvizaibptmycu (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 to Expert-Tailored Solutions

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

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

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

Get Started

Recommended Textbook for

Data Mining Concepts And Techniques

Authors: Jiawei Han, Micheline Kamber, Jian Pei

3rd Edition

0123814790, 9780123814791

More Books

Students also viewed these Databases questions

Question

gpt 6 5 9

Answered: 1 week ago