В задаче Password Validation не проходит задачи 10 и 11 | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

В задаче Password Validation не проходит задачи 10 и 11

a=input() b=0 z={"!","@","#","

quot;,"%","&","*"} for i in a: b+=i.isdigit() t=z.intersection(a) c=len(t) d=len(a) if b>=2 and c>=2 and d>=7: print ("Strong") else: print("Weak")

7th Mar 2022, 6:36 PM
denis
2 Answers
+ 1
Спасибо
7th Mar 2022, 6:51 PM
denis
0
если ввод имеет повторяющиеся специальные символы, такие как @@12abc не работает. потому что t=z.intersection(a) возвращает один {@}, но нужно {@,@} if input have duplicate special characters like @@12abc it fails. because t=z.intersection(a) return single {@} but need {@,@}
7th Mar 2022, 6:50 PM
Jayakrishna 🇮🇳