+ 1

what is wrong with this code? 10 and 11 tests fail. And yes, I know that the code is not readable. but someone help

https://code.sololearn.com/cPvbqavHqNz4/?ref=app

2nd Oct 2022, 8:09 PM
klq
klq - avatar
3 Respostas
+ 4
Special character & is missing...
2nd Oct 2022, 8:13 PM
Jayakrishna 🇮🇳
+ 2
thank you very much, I understand
4th Oct 2022, 2:31 AM
klq
klq - avatar
+ 1
// add "&" << this special character in you list pswrd = input() special_symbol = ['!', '@', '#', '
#x27;, '%', '*', "&"] #✅✅✅ nmbr = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'] number = [0 , 1 , 2 , 3, 4, 5, 6, 7, 8, 9] spcsymbl_in_pswrd = 0 nmbr_in_pswrd = 0 for x in pswrd: if x in special_symbol: spcsymbl_in_pswrd = spcsymbl_in_pswrd+1 elif x in nmbr: nmbr_in_pswrd = nmbr_in_pswrd + 1 if len(pswrd) >= 7: if spcsymbl_in_pswrd >= 2: if nmbr_in_pswrd >= 2: print('Strong') else: print('Weak') else: print('Weak') else: print('Weak')
3rd Oct 2022, 7:14 AM
Jitendra
Jitendra - avatar