Viganere cipher and Hill cipher
. Have a function with the name "vigenere_enc" that accepts a string as its first and second argument and returns a string.
e.g., function call: vigenere_enc('KEY', 'Test String') should return a string 'DIQDWRBMLQ'
. Have a function with the name "vigenere_dec" that accepts a string as its first and second argument and returns a string.
e.g., function call: vigenere_dec('KEY', 'DIQDWRBMLQ') should return a string 'TESTSTRING'
. Have a function with the name "hill_enc" that accepts a Matrix (3x3) as its first argument and a string as its second argument and returns a string. This function should make sure that the processed input string is padded with "X" or "XX" to make the input length a multiple of 3.
e.g., function call: hill_enc(M, 'Test String') should return a string 'BPBLJCPRGHQO'; where M has the value as shown in the code snippet below:
using numpy as np
M = np.array([[17,17,5],[21,18,21],[2,2,19]])
. Have a function with the name "hill_dec" that accepts a Matrix (3x3) as its first argument and a string as its second argument and returns a string. This function should make sure that the processed input string is padded with "X" or "XX" to make the input length a multiple of 3.
e.g., function call: hill_dec(M, 'BPBLJCPRGHQO') should return a string 'TESTSTRINGXX'; where M has the value as shown in the code snippet below:
using numpy as np
M = np.array([[17,17,5],[21,18,21],[2,2,19]])
5 years ago
5
- ECO 100 week 5 Final paper
- ACC 400 Complete Class / ACC 400 Entire Course
- calc
- international business
- Health Care Financing Paper 1
- Administrator, and you have been tasked with implementing
- Provide your observations on how well the United States is protected against threats from
- Case Study: Mobile Device Security and Other Threats
- BUAD3030
- Assignment 4: VoIP Part 4 (Risk Register)