Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Program is to be wrriten in C language One of the oldest known encryption techniques is the Caesar cipher attributed to Julius Caesar. It involves

Program is to be wrriten in C language

image text in transcribed

image text in transcribed

One of the oldest known encryption techniques is the Caesar cipher attributed to Julius Caesar. It involves replacing each letter of a message with another letter that is a fixed number of positions later in the alphabet. We note that if the replacement would go past the letter Z, the cipher "wraps around" to the beginning of the alphabet. For example if each letter is replaced by the letter two positions after it, then Y would be replaced A, and Z would be replaced by B. Write a program that encrypts a message using a Caesar cipher. The user will enter the message to be encrypted and the shift amount (the number of positions by which letters should be shifted): Enter message to be encrypted: Go ahead, make my day. Enter shift amount (1 -25): 3 Encrypted message: Jr dkhdg, pdnh pb gdb. Notice that the program can decrypt a message if the user enters 26 minus the original key: Enter message to be encrypted: Jr dkbdg, pdnh pb gdb. Enter shift amount (1 -25): 23 Encrypted message: Go ahead, make my day. You may assume that the message does not exceed 80 characters. Characters other than letters should be left unchanged. Lower-case letters remain lower-case when encrypted and upper case letters remain upper-case

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

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

Recommended Textbook for

Modern Database Management

Authors: Jeffrey A. Hoffer Fred R. McFadden

9th Edition

B01JXPZ7AK, 9780805360479

More Books

Students also viewed these Databases questions

Question

=+ b. How would the change you describe in part

Answered: 1 week ago

Question

=+ 6. A Case Study in this chapter concludes that if

Answered: 1 week ago