Abcdef12
YES
import sys
pw=sys.stdin.read().strip()
if pw is None: sys.exit(0)
class Validator:
def __init__(self,pw):
self.pw=pw
def ok(self):
if len(self.pw)<8:
return False
hasD=False
hasU=False
hasL=False
for ch in self.pw:
o=ord(ch)
if 48<=o<=57:
hasD=True
elif 65<=o<=90:
hasU=True
elif 97<=o<=122:
hasL=True
return hasD and hasU and hasL
print('YES' if Validator(pw).ok() else 'NO')
import sys
pw=sys.stdin.read().strip()
if pw is None: sys.exit(0)
class Validator:
def __init__(self,pw):
self.pw=pw
def ok(self):
if len(self.pw)<8:
return False
hasD=False
hasU=False
hasL=False
for ch in self.pw:
o=ord(ch)
if 48<=o<=57:
hasD=True
elif 65<=o<=90:
hasU=True
elif 97<=o<=122:
hasL=True
return hasD and hasU and hasL
print('YES' if Validator(pw).ok() else 'NO')