# Learn String Manipulation by Building a Cipher - Step 41

### Tell us what’s happening:

Need to compare char and space (‘’) using == operations, I tried but code not getting pass through

``````
# User Editable Region

text = 'Hello World'
shift = 3
alphabet = 'abcdefghijklmnopqrstuvwxyz'
encrypted_text = ''

for char in text.lower():
print(char == '')
index = alphabet.find(char)
new_index = index + shift
encrypted_text += alphabet[new_index]
print('char:',char,'encrypted text:',encrypted_text)

# User Editable Region

``````

User Agent is: `Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Mobile Safari/537.36`

### Challenge Information:

Learn String Manipulation by Building a Cipher - Step 41

You appear to have created this post without editing the template. Please edit your post to Tell us what’s happening in your own words.

### Tell us what’s happening:

At the beginning of your loop body, print the result of comparing `char` with a space (`' '` ). Use the equality operator `==` for that. I have tired but code doesn’t pass through… kindly help

``````
# User Editable Region

text = 'Hello World'
shift = 3
alphabet = 'abcdefghijklmnopqrstuvwxyz'
encrypted_text = ''

for char in text.lower():
print(char == '')
index = alphabet.find(char)
new_index = index + shift
encrypted_text += alphabet[new_index]
print('char:',char,'encrypted text:',encrypted_text)

# User Editable Region

``````

User Agent is: `Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Mobile Safari/537.36`

### Challenge Information:

Learn String Manipulation by Building a Cipher - Step 41

this is not a space, you need to write a space between the quotes for the string to contain a space

1 Like

try :- print(‘char is space:’,char == ’ ').

hope it will work, i got my output but it still throw error.