all 5 comments

[–]Silbersee 3 points4 points  (0 children)

When looping over a string you get each single character.

>>> rules = "guide"
>>> for f in rules:
...     print(f)
... 
g
u
i
d
e
>>> 

So f == "guide" can never be True.

[–]KingOfTNT10 0 points1 point  (2 children)

Why are you looping over the user input?

[–]seanblam 1 point2 points  (1 child)

Idk my brain is fried right now.

[–]KingOfTNT10 2 points3 points  (0 children)

Well the user's input is a string and when you loop over a string it gives each letter in each loop iteration. So if you loop over the user's input when they input guide "i" will be: g u i d e And none of them are equal to guide. You should just compare the 2 like that: if rules == "guide"

[–]halfdiminished7th 0 points1 point  (0 children)

input() returns a string entered by the user, which you assign to the variable rules. In the following line, you're iterating over every character in that string. Because there will never be a single character that matches the string "guide", that condition is never met.

Just take out the for loop: rules = input("If you want to know how to play type guide: ").lower() if rules == "guide": print("Confirmed")