Python code
Entry level code 1. (2 points) (Attacking the Camar C pher.) we dinmd how the Camar Opher .u. ceptible to a bnde force attack sincs there sre only 25 ponsible keys (1-25)Write a function caesarBrute that, given a ciphertext s input, prints to the screen every poible decryption Use this function to find the mege that led to 'h Ivicm and pat the anower ina comment under your funetion. You are weloome to use any of the functions we wrote in clase but need to copy these functions Into your lab 2. (3 polnta) (Two-Key Caesar Clipher.) ls the two-lny Camar Cipher, there are two keys key even and key od4, each a number from 1 to 25. Letters in even positions are ahifted over key-even spots, while letters in odd positices in the string are shifted over key.odd spots Implement encryption and decryption funetions for this cipber and twoCaeBaTDec. As with the modidcations you made to the Can should only shift letten Md handle both upper and lower letters (Hat; your enryption function wil now take three anguments insted of just two.) your functlons 3. (2 polnta) (A Transposition Cipben Swap-Them.) To encrypt a string uing the Swap- Them transposition eipber, the character in position is swapped with the character in poi tion Cker-)%aen (e). Inpinet eeryption and demtin functions for this cipher called evaperc and avapdec For example, avapenc(4,srong wind) should return sortedsiu (4 polista) (Acronyms.) An acronymm is a wond formed by taking the first letters of the word in a phrase and making a word from them For exmple, RAM is an acronym foe d access memory." Write a function acronys that takes one inpat string and then outputs the acronym for that phrae. Nober the scroaym should be all uppercaee, even if the words in the phrase are sot capitalined. For example acronym Randos access sesory) should returs RAN'.(Hint: don't forget to test striign with maltiple spaos sad spaces at the begini%) Note that since we hve ot covered lats, you may ht use any string functons or methods that return lists (o-g, split ia ot allowed)