Posted January 13Jan 13 Write a program that implements a Caesar Cipher, one of the simplest encryption techniques. The program should be able to both encrypt and decrypt text using a given shift value.Basic Requirements:Accept a message from the user.Accept a shift value (e.g., 3 shifts each letter forward by 3).Provide options to encrypt or decrypt the message.Handle both uppercase and lowercase letters.Bonus Features:Handle non-alphabetic characters by leaving them unchanged.Allow the user to brute-force decrypt a message by trying all possible shift values.Implement a case-insensitive mode to ignore letter casing in the input.Example Output:Choose an option: (1) Encrypt (2) Decrypt > 1 Enter the message: Hello World! Enter shift value: 3 Encrypted message: Khoor Zruog! Choose an option: (1) Encrypt (2) Decrypt > 2 Enter the message: Khoor Zruog! Enter shift value: 3 Decrypted message: Hello World!
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.