Question
How do you combine cipher codes, specifically caesar, atbash, and a1z26? I already made user-defined functions for all the ciphers. However, I keep getting the
How do you combine cipher codes, specifically caesar, atbash, and a1z26? I already made user-defined functions for all the ciphers. However, I keep getting the error the string is not callable. I just need to combine them in a specific way under one main function that looks like the following:
def main() -> None:
1. The user must enter a text to cipher.
2. The program should print the following ciphers in this format.
- print - Caesar cipher - print - Atbash cipher - print - first apply Caesar cipher onto text, then Atbash cipher on the text that was just ciphered by the Caesar cipher - print - first apply Atbash cipher on text, then Caesar cipher on that text -print - A1Z26 cipher - print - first apply A1Z26 cipher on the text, then Caesar cipher on top of the text that was just ciphered by A1Z26 -print - first apply A1Z26 cipher on the text, then Atbash cipher on top of that text - print - first apply A1Z26 cipher on the text, then Atbash cipher, then Caesar cipher - print - first apply A1Z26 cipher, then Caesar cipher, then Atbash cipher
Essentially, the program should take the input text and be ciphered by one code and now that that text must to be ciphered again by another code on top.
*** remember you cannot make your own function for each print-out it must be under the ONE def main(). No breaks and no global values. Must be on python.
Here is a sample output: (it must also work if the user decides to enter letters instead of numbers)
The user enters the following: 4-16-19 11-23-10 20-9-1-10-5-4-23-15-6-5 15-5 2-19-6-25 21-12-19-2-19-6
then press Enter.
The program should print:
Caesar cipher: 4-16-19 11-23-10 20-9-1-10-5-4-23-15-6-5 15-5 2-19-6-25 21-12-19-2-19-6 Atbash cipher: 4-16-19 11-23-10 20-9-1-10-5-4-23-15-6-5 15-5 2-19-6-25 21-12-19-2-19-6 Combined: 1) Caesar; 2) Atbash cipher: 4-16-19 11-23-10 20-9-1-10-5-4-23-15-6-5 15-5 2-19-6-25 21-12-19-2-19-6 Combined: 1) Atbash; 2) Caesar cipher: 4-16-19 11-23-10 20-9-1-10-5-4-23-15-6-5 15-5 2-19-6-25 21-12-19-2-19-6 A1Z26 cipher: DPS KWJ TIAJEDWOFE OE BSFY ULSBSF Combined: 1) A1Z26; 2) Caesar cipher: AMP HTG QFXGBATLCB LB YPCV RIPYPC Combined: 1) A1Z26; 2) Atbash cipher: WKH PDQ GRZQVWDLUV LV YHUB FOHYHU Combined: 1) A1Z26; 2) Atbash; 3) Caesar cipher: THE MAN DOWNSTAIRS IS VERY CLEVER Combined: 1) A1Z26; 2) Caesar; 3) Atbash cipher: ZNK SGT JUCTYZGOXY OY BKXE IRKBKX
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started