Question: python3.6 6.35 The Caesar cipher is an encryption technique in which every letter of the message is replaced by the letter that is a fixed
6.35 The Caesar cipher is an encryption technique in which every letter of the message is replaced by the letter that is a fixed number of positions down the alphabet. This "fixed number" is referred to as the key, which can have any value from 1 to 25. If the key is 4, for example, then letter A would be replaced by E, B by F, C by G, and so on. Characters at the end of the alphabet, W, X, Y, and Z would be replaced by A, B, C, and D. Write function caesar that takes as input a key between 1 and 25 and a text file name (a string). Your function should encode the file content with a Caesar cipher using the input key and write the encrypted content into a new file cipher.txt (as well as print it on the screen). >> caesar (3,'clear.txt "Vsb Pdqxdo (Wrs vhfuhu) nin1. Dozdbv zhdu d gdun frdw. In2. Dozdbv zhdu brxu djhgfb'v edgjh rq brxu frd.In" xt
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
