subject

You have been given an encrypted copy of the Final exam study guide here, but how do you decrypt and read it??? Along with the encrypted copy, some mysterious person has also given you the following documents:

helloworld. txt -- Maybe this file decrypts to say "Hello world!". Hmmm.

hints. txt -- Seems important.

In a file called pa11.py write a method called decode(inputfile, outputfile). Decode should take two parameters - both of which are strings. The first should be the name of an encoded file (either helloworld. txt or .txt or yet another file that I might use to test your code). The second should be the name of a file that you will use as an output file. For example:

decode(".txt" , "translatedguide. txt")

Your method should read in the contents of the inputfile and, using the scheme described in the hints. txt file above, decode the hidden message, writing to the outputfile as it goes (or all at once when it is done depending on what you decide to use).

Hint: The penny math lecture is here.

Another hint: Don't forget about while loops...

Mac hint: use encoding="utf-8" in your file open functions, like this:

Mac hint: use encoding="ascii" in your file open functions, like this:

fin = open(input_file,"r",encoding="ascii ")

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 09:10
Effective character encoding requires standardized code. compatible browsers. common languages. identical operating systems.
Answers: 1
question
Computers and Technology, 23.06.2019 16:30
If i wanted to include a built-in calendar in a document, what option could i select? draw table insert table insert chart quick tables
Answers: 1
question
Computers and Technology, 24.06.2019 00:30
Asecurity policy is a a. set of guidlines b. set of transmission protocols c. written document d. set of rules based on standards and guidelines
Answers: 2
question
Computers and Technology, 24.06.2019 01:30
Write a program that asks the user to enter the name of an input file. if the file does not exist, the program should prompt the user to enter the file name again. if the user types quit in any uppercase/lowercase combinations, then the program should exit without any further output.
Answers: 3
You know the right answer?
You have been given an encrypted copy of the Final exam study guide here, but how do you decrypt and...
Questions
question
Mathematics, 17.05.2020 23:57
question
Mathematics, 17.05.2020 23:57