This is as far as I have managed to code the Caesar cipher.
def caesar():
alphabet = 'abcdefghijklmnopqrstuvwxyz'
shift = 5
shifted_alphabet = alphabet\[shift:\] + alphabet\[:shift\]
translation_table = str.maketrans(alphabet, shifted_alphabet)
text = 'hello world'
encrypted_text = text.translate(translation_table)
print(encrypted_text)
def caesar (text,shift):
alphabet = 'abcdefghijklmnopqrstuvwxyz'
offsetted_alphabet = alphabet\[offset:\] + alphabet\[:offset\]
translation_table = str.maketrans(alphabet, offsetted_alphabet)
message = 'hello world'
encrypted_message = message.translate(translation_table)
`
Instructions are not to use text and shift, so i changed to messge and offset. It still did not pass. Please help.
