>1of 3100%aipnabet to the left. Tne amount of the snift is referred to as the key . For exampie, it we are encryptingthe letter A, and we shift the alphabet four times to the left (that is, the...


File Edit<br>View History Bookmarks Tools Help<br>COMPSCI 119: I V×<br>Young LeadershipX<br>SWS Sign Up to X<br>New Tab<br>Grades: View<br>4-1.pdf<br>C How Do I Write TX<br>b My Questions | b.X<br>Cryptography wit X<br>+<br>& file:///C:/Users/msunn/AppData/Local/Temp/Lab%234-1.pdf<br>G<br>个|小<br>+<br>>><br>1<br>of 3<br>100%<br>aipnabet to the left. Tne amount of the snift is referred to as the key . For exampie, it we are encrypting<br>the letter A, and we shift the alphabet four times to the left (that is, the key is 4), then A becomes E in our<br>encryption. Decryption proceeds in the opposite manner, where E is decrypted back into an A.<br>Your Task<br>Your task is to write a program called Lab4.py to decode and print the secret message in SecretCode.txt<br>file, which you can download from Moodle. Put the downloaded file in the same folder as your program.<br>This file has text that has been encrypted using a Caesar Cipher. Your program will need to read the<br>encrypted text from the file, and then take an integer decryption key as input from the user. Your program<br>must then print the decrypted output on the console.<br>You are required to put your solution code into a function called Main that has no arguments. That is, the<br>framework of your program must appear as follows (do NOT forget the comment with your name):<br># Your name<br>Lab #4<br>the current date<br>def ReadFileAsListOfStrings (Filename):<br># Get the code from the Companion, bottom of page 366<br>def Main ):<br>Code<br>ReadFileAsListOfStrings (

Extracted text: File Edit View History Bookmarks Tools Help COMPSCI 119: I V× Young LeadershipX SWS Sign Up to X New Tab Grades: View 4-1.pdf C How Do I Write TX b My Questions | b.X Cryptography wit X + & file:///C:/Users/msunn/AppData/Local/Temp/Lab%234-1.pdf G 个|小 + >> 1 of 3 100% aipnabet to the left. Tne amount of the snift is referred to as the key . For exampie, it we are encrypting the letter A, and we shift the alphabet four times to the left (that is, the key is 4), then A becomes E in our encryption. Decryption proceeds in the opposite manner, where E is decrypted back into an A. Your Task Your task is to write a program called Lab4.py to decode and print the secret message in SecretCode.txt file, which you can download from Moodle. Put the downloaded file in the same folder as your program. This file has text that has been encrypted using a Caesar Cipher. Your program will need to read the encrypted text from the file, and then take an integer decryption key as input from the user. Your program must then print the decrypted output on the console. You are required to put your solution code into a function called Main that has no arguments. That is, the framework of your program must appear as follows (do NOT forget the comment with your name): # Your name Lab #4 the current date def ReadFileAsListOfStrings (Filename): # Get the code from the Companion, bottom of page 366 def Main ): Code ReadFileAsListOfStrings ("SecretCode.txt") # All your new code goes here return - Page 1 Lab Assignment 4 – Professor William T. Verts Written by TAs Prateek Mantri and Sunjae Kwan, and Matthew Jamieson, © 2021 COMPSCI 119 – Fall 2021 One approach could be to convert characters into numbers, where they can be added and subtracted before being converted back in to characters. Alternatively, you can store the alphabet in a list and address its elements by index. 11:10 PM O Type here to search 25 36°F 11/19/2021
Jun 04, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here