Write a python program that ciphers a plain text message using double transposition scheme and vice...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Write a python program that ciphers a plain text message using double transposition scheme and vice versa. The program should accept five tuples of input: plain text, row, column, permutation of row and columns. An example of encrypted text for the plain text "attack at dawn" is shown below. Plain text: attack at dawn Matrix row size: 5 Matrix column size: 3 Row permutation order: 3, 5, 1, 4, 2 Column permutation order: 1, 3, 2 Encrypted text: xtawxnattxadakc Similarly, your program should decrypt the encrypted text given the encrypted text, matrix row is shown and column sizes, row, and column permutation order. An example snapshot of output below: Encrypted text: xtawxnattxadake Matrix row size: 5 Matrix column size: 3 Row permutation order: 3, 5, 1, 4, 2 Column permutation order: 1. 3. 2 Plain text: attack at dawn Write a python program that ciphers a plain text message using double transposition scheme and vice versa. The program should accept five tuples of input: plain text, row, column, permutation of row and columns. An example of encrypted text for the plain text "attack at dawn" is shown below. Plain text: attack at dawn Matrix row size: 5 Matrix column size: 3 Row permutation order: 3, 5, 1, 4, 2 Column permutation order: 1, 3, 2 Encrypted text: xtawxnattxadakc Similarly, your program should decrypt the encrypted text given the encrypted text, matrix row is shown and column sizes, row, and column permutation order. An example snapshot of output below: Encrypted text: xtawxnattxadake Matrix row size: 5 Matrix column size: 3 Row permutation order: 3, 5, 1, 4, 2 Column permutation order: 1. 3. 2 Plain text: attack at dawn
Expert Answer:
Answer rating: 100% (QA)
Encryption Transposition Cipher Encryption import pyperclip def main myMessage attack at dawn myKey 8 ciphertext encryptMessagemyKey myMessage Print t... View the full answer
Related Book For
Data Structures and Algorithms in Python
ISBN: 978-1118290279
1st edition
Authors: Michael T. Goodrich , Roberto Tamassia, Michael H. Goldwasser
Posted Date:
Students also viewed these programming questions
-
Suppose you have Rs.300 to invest in a portfolio of two assets. Return on asset 1 is 10% and return on asset 2 is 20% Risk on portfolio of 1 and 2 is zero. A) price of both assets=Rs.100 B)price of...
-
Python 3 Write a python program that generates 1,000 random integers between 0 and 9 and displays the count for each number (Hint: Use a list of ten integers, say counts, to store the counts for the...
-
Write a Python program that outputs all possible strings formed by using the characters 'c', 'a', 't', 'd', 'o', and g exactly once.
-
1. Green logistics advocates a type of SCM that minimizes the environmental impacts including climate change, air pollution, water pollution, soil degradation, solid waste, noise, vibration, and...
-
Micro Systems is evaluating a $50,000 project with the following cash flows. Years Cash Flows 1 ................................$ 9,000 2 ................................12,000 3...
-
____ is the abbreviation for alpha.
-
A university pumps its water from wells located on campus. The falling water table has caused pumping costs to increase, the quantity of water available to decrease, and the quality of water to...
-
Eddie Kelly is running for reelection as mayor of a small town in Alabama. Jessica Martinez, Kelly's campaign manager during this election, is planning the marketing campaign, and there is some stiff...
-
1. When was Bed bath and beyond founded and when did it go "public"? 2. In what industry is BBB located? who are its main competitors? 3. Which of BBB's competitors has been doing well? What is the...
-
Assume that there are two nations in the world, Ireland, and Switzerland, and that each country can produce only two products. Each country uses half of its resources on each product. They can...
-
Based on the given income statement for 2021: 1. Based on recent fiscal year financials use a percentage of sales model to estimate your firm's sales, net income, debt and equity in the next fiscal...
-
For the past ten years, Savco has obtained its best employees from private employment agencies. Now that it has three additional jobs to fill, it will probably, [A] a skills inventory. [B] external...
-
Parallel processing describes a computer operation in which Select one: a. program instructions are queued up for processing on a single core or CPU. b. a single program instruction is executed on...
-
1. (18 points) ABC Computer Company shows the following information on its pro forma income statement and statement of financial position: 2023 Sale Cost of goods sold Depreciation Interest Tax rate...
-
A 0.63 - mm - diameter copper wire carries a tiny current of 2.5A. The molar mass of copper is 63.5 m ole and its density is 8900k-9.N = 6.02 x 103 3 m Part A Estimate the electron drift velocity....
-
Choose a computer security certification to research. Describe what the certification covers. Research the requirements to obtain (and maintain) the certification. Write a two-to three-paragraph...
-
Background of two hospitals for merger: Community Memorial Health System What originated in 1901 as a single hospital serving its neighbors has grown into a comprehensive healthcare system that...
-
Archangel Corporation prepared the following variance report. Instructions Fill in the appropriate amounts or letters for the question marks in the report. ARCHANGEL CORPORATION Variance...
-
What values are returned during the following sequence of deque ADT operations, on initially empty deque? add first(4), add last(8), add last(9), add first(5), back(), delete first( ), delete last(...
-
Suppose you are given a timetable, which consists of: A set A of n airports, and for each airport a in A, a minimum connecting time c(a). A set F of m flights, and the following, for each flight f...
-
Write a short Python function that takes a sequence of integer values and determines if there is a distinct pair of numbers in the sequence whose product is odd.
-
Identify the most promising areas of research for future researchers in the area of hedge fund systemic risk.
-
Discuss how hedge funds and the potential for shadow banking may contribute to systemic risk and the prospect for contagion.
-
Explain the relation between hedge fund characteristics and risks.
Study smarter with the SolutionInn App