Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

ng the meaning of messages by putting them in some kind of codeis something we have all done, from the coding rings' and secret symbols

image text in transcribed
image text in transcribed
image text in transcribed
ng the meaning of messages by putting them in some kind of codeis something we have all done, from the "coding rings' and secret symbols of childhood to the top secrecy of military and commercial establishments' secret data. In fact, some of the earliest uses of computers were for coding, messages and coded messages. Newer coding methods are among the most interesting research areas in computer science today The Caesar Cipher nicate with his army. Caesar is ided that shifting each letter in the message One of the simplest examples of a substitution cipher is the Caesar Cipher, which is said to have been used by Julius Caesar to commu considered to be one of the first persons to have ever employed encryption for the sake of securing messages. Caesar dec would be his standard algorithm, and so he informed all of his generals of his decision, and was then able to send them secured messages. Us right), the message, Caesar Shift (3 to the RETURNTOROME would be encrypted as UHwXUQwRURPH In this example, RH and so on. Now, even if the enemy did interce pt the message, it would be useless, since only Caesar's generals could read it The Assignment Write a program to implement the Caesar Cipher Problem Write a program that will prog9- IN.txt file. Your input fle should start with a line with a single enumerated value O-encrypt and 1-decrypt. Subsequent lines will be used for the message If 'encrypt, your program am should decrypt the files contents by shifting each character (including white space) 3 values to the left If the file fails to open your program should print an error message and exit printouts should be displayed BOTH on the screen and also written to an output file named progy.OUT.xt

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

Database Processing Fundamentals Design And Implementation

Authors: David M. Kroenke

5th Edition

B000CSIH5A, 978-0023668814

More Books

Students also viewed these Databases questions