import string
pwd = input("请输入密码:")
def check(pwd):
if not isinstance(pwd,str) or len(pwd)<6:
return '密码不符合要求'
d={1:'弱',2:'低于中等',3:'中等以上',4:'强'}
r=[False]*4
for ch in pwd:
if not r[0] and ch in string.digits:
r[0]=True
elif not r[1] and ch in string.ascii_lowercase:
r[1]=True
elif not r[2] and ch in string.ascii_uppercase:
r[2]=True
elif not r[3] and ch in ',.!;?<>':
r[3]=True
return d.get(r.count(True),'错误')
print(check(pwd))