Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2018
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. import re
  2. password = input("Введите пароль не менее 8 символов и не более 64")
  3. # Проверяем длину пароля
  4. if 0 < len(password) <= 64:
  5. if re.match("[a-zA-Z0-9]+", password):
  6. print('Збс')
  7. digit = False
  8. lower = False
  9. upper = False
  10. if str.isdigit(password):
  11. digit = True
  12. print(digit)
  13. if str.islower(password):
  14. lower = True
  15. print(lower)
  16. if str.isupper(password):
  17. upper = True
  18. print(upper)
  19. # if digit=True and lower = True and upper = True:
  20.  
  21. # if str.isdigit(password) == True and str.islower(password) == True and str.isupper(password) == True:
  22. print('Кросавчег')
  23. # else:
  24. # print('неправильный пароль!')
  25. else:
  26. print('неправильный пароль!')
  27. else:
  28. print('неправильный пароль!')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement