# What do you need to do to make the cycle work?

• I need to be able to accidentally introduce "'m1','m9','p1','p9','s1','s9',WEST,SOUTH,NORTH,EAST,WHITE,RED,GREEN," but whatever procedure I've put in, the cycle shows that he doesn't know that combination.

``````#тайлы ман
m={'m1','m2','m3','m4','m5','m6','m7','m8','m9'}
#тайлы пин
p={'p1','p2','p3','p4','p5','p6','p7','p8','p9'}
#тайлы соу
s={'s1','s2','s3','s4','s5','s6','s7','s8','s9'}
#ветра
w={'W','S','N','E'}
#драконы
d={'Wh','R','G'}
WEST='W'
SOUTH='S'
NORTH='N'
EAST='E'
WHITE='Wh'
RED='R'
GREEN='G'
#кокуши мусо
k_m= ('m1','m9','p1','p9','s1','s9',WEST,SOUTH,NORTH,EAST,WHITE,RED,GREEN)
#ввод твоей руки
hand=input ('какая у тебя рука?')
while hand==k_m:
#если рука кокуши
print('у тебя кокуши')
break
if hand!=k_m:
#если рука не кокуши
print('я не знаю такой комбинации')
``````

• I'll show you how to steam the entry and check:

``````test = ('a', 'b', 'c')
def check_input(inp):
return sorted(map(str.strip, inp.split(','))) == sorted(test)
assert check_input('a,c,  b') == True
assert check_input('a,c, b,d') == False
assert check_input('c, a,b') == True
assert check_input('c, a') == False
``````

This is provided that the mortgages can be repeated, and the existence of a second similar vein (or vice versa of the second vein) breaks the combination. If you don't break the combination, you just need to write. `set` both `sorted`

2

2

2

2

2

2

2

2

2

2

2

2

2

2

2