Question: Write a program which implements the Caesar cipher. It is required that the encryption and decryption algorithms in your implementation will use the functions implemented

Write a program which implements the Caesar cipher. It is required that the encryption and decryption algorithms in your implementation will use the functions implemented in Question 2. Your submission must include the code of your program as well as screenshots showing three test runs for the plaintext back and the values of key 3,5,19.c)
24+14=(mod26)
24+14=38
38-261=38-26=12
Therefore, 24+14-=12(mod26)
[15 points =5 points per item]
[Modular arithmetic: implementation] Write a program
which implements a modular addition and a modular
subtraction. For simplicity, you may fix the modulus to be 26.
A modular addition will be implemented as a function
m_add(a,b) which take integers "a" and "b" as inputs and
outputs
a+b(mod26). For simplicity, you may assume that ,
1,dots,25. Similarly, a function m?sub(a,b) will implement a
b (mod 26). Your submission must include the code of your
program (enclosed as a separate file) as well as screenshots
(included into the homework report) showing test runs for the
values from Question 1 items (b) and (c).
[40 points: 20 points per function]
[Caesar cipher: implementation] Write a program which
implements the Caesar cipher. It is required that the
encryption and decryption algorithms in your implementation
will use the functions implemented in Question 2. Your
submission must include the code of your program as well as
screenshots showing three test runs for the plaintext "back"
and the values of key 3,5,19.
[15 points]
[Exclusive-OR using modular arithmetic] Let us consider a
representation of the Exclusive-OR (XOR) function using
modular arithmetic. Compute the following:
a)1+1=(mod2)
Explanation:
1+1=2
2-12=2-2=0
Therefore: 1+1=0(mod2). This result aligns with the
behavior of the XOR function, where the sum of two
equal bits is 0.
 Write a program which implements the Caesar cipher. It is required

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!