tsrha
November 29, 2025, 3:02am
1
Tell us what’s happening:
I am building the Caesar Cipher . I am using the example code and the Sentence[star:stop] suggestion also just to keep trying.
I need help.
Your code so far
# User Editable Region
alphabet = 'abcdefghijklmnopqrstuvwxyz'
shift = 5
shifted_alphabet = alphabet[shift:]
print(shifted_alphabet)
shifted_alphabet = 'alphabet[6:15]' + ' ' + 'alphabet[0:4]'
# User Editable Region
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:145.0) Gecko/20100101 Firefox/145.0
Challenge Information:
Build a Caesar Cipher - Step 4
Teller
November 29, 2025, 5:55am
2
Hi @tsrha
For this step you need to modify the existing shifted_alphabet variable.
Carefully look at the example code to see what you need to do.
Please reset the step to restore the seed code and try again.
Happy coding
tsrha
November 29, 2025, 1:59pm
3
I tried cipher_alphabet instead, dropped the quotations, the numbers etc back and forth. Nothing works. help!
Hello @tsrha your code should look something like this if i remember. alphabet = ‘abcdefghijklmnopqrstuvwxyz’
shift = 5
shifted_alphabet = alphabet[shift:]
print(shifted_alphabet)
Hope to hear from you soon.
ILM
November 29, 2025, 4:29pm
5
that variable is not accepted in this step, reset the step, and complete the line in which shifted_alphabet is created
tsrha
November 29, 2025, 6:30pm
6
i have below now . Does not pass
shifted_alphabet = alphabet[shift:] + alphabet[:shift]
ILM
November 29, 2025, 6:31pm
7
please share all your code
tsrha
November 29, 2025, 6:33pm
8
alphabet = ‘abcdefghijklmnopqrstuvwxyz’
shift = 5
shifted_alphabet = alphabet[shift:]
print(shifted_alphabet)
shifted_alphabet = alphabet[shift:] + alphabet[:shift]
ILM
November 29, 2025, 6:35pm
9
you have added a new line, that’s wrong, reset the step, complete the existing line
tsrha
November 29, 2025, 6:44pm
10
alphabet = ‘abcdefghijklmnopqrstuvwxyz’
shift = 5
shifted_alphabet = alphabet[shift:]
print(shifted_alphabet)
shifted_alphabet = ‘alphabet[6:26]’ + ’ ’ + ‘alphabet[0:5]’
This is the slicing according to the example code.
tsrha
November 29, 2025, 7:14pm
11
i have excluded the stops here
shifted_alphabet = ‘alphabet[6:25]’ + ’ ’ + ‘alphabet[0:4]’
Teller
November 29, 2025, 8:13pm
12
Hi @tsrha
In one of the above posts containing only five lines of code, you have the correct line of code, but was placed on a new line. You are not asked to write a new line of code. You are asked to modify an existing expression.
Please reset the step to restore the seed code.
You will need to use the shift variable, do not hard code values.
Happy coding
tsrha
November 29, 2025, 8:26pm
13
Please tell me if this is above or below the print command
tsrha
November 29, 2025, 8:49pm
14
Thank you. Existing is the magic word!!!
1 Like