def checkLens(strs:str) -> int:
if not strs:
return 0
lens = len(strs)
if lens <= 4:
return 5
elif 5 <= lens <= 7:
return 10
else:
return 25
def checkChar(strs:str) -> int:
if not strs:
return 0
MaxChar = 0
MinChar = 0
for x in strs:
if x.islower():
MinChar += 1
elif x.isupper():
MaxChar += 1
if MaxChar and MinChar:
return 20
elif MaxChar or MinChar:
return 10
else:
return 0
def checkNum(strs:str) -> int:
if not strs:
return 0
NumCount = 0
for x in strs:
if x.isdigit():
NumCount += 1
if NumCount > 1:
break
if NumCount == 0:
return 0
elif NumCount == 1:
return 10
else:
return 20
def checkSpace(strs:str) -> int:
if not strs:
return 0
SpaceCount = 0
for x in strs:
if not x.isdigit() and not x.islower() and not x.isupper():
SpaceCount += 1
if SpaceCount > 1:
break
if SpaceCount == 0:
return 0
elif SpaceCount == 1:
return 10
else:
return 25
def checkName(strs:str) -> int:
if not strs:
return 0
SpaceCount = 0
NumCount = 0
MaxChar = 0
MinChar = 0
for x in strs:
if x.isdigit():
NumCount += 1
elif x.islower():
MinChar += 1
elif x.isupper():
MaxChar += 1
else:
SpaceCount += 1
if SpaceCount and NumCount and MaxChar and MinChar:
return 5
elif SpaceCount and NumCount and (MaxChar or MinChar):
return 3
elif NumCount and (MaxChar or MinChar):
return 2
else:
return 0
def checkScord(strs:str) -> str:
lensCount = checkLens(strs)
#print("lensCount", lensCount)
CharCount = checkChar(strs)
#print("CharCount", CharCount)
NumCount = checkNum(strs)
#print("NumCount", NumCount)
NameCount = checkName(strs)
#print("NameCount", NameCount)
SpaceCount = checkSpace(strs)
#print("SpaceCount", SpaceCount)
AllCount = lensCount + CharCount + NumCount + NameCount + SpaceCount
if AllCount >= 90:
return "VERY_SECURE"
elif AllCount >= 80:
return "SECURE"
elif AllCount >= 70:
return "VERY_STRONG"
elif AllCount >= 60:
return "STRONG"
elif AllCount >= 50:
return "AVERAGE"
elif AllCount >= 25:
return "WEAK"
elif AllCount >= 0:
return "VERY_WEAK"
while True:
try:
strs = input()
NewStr = checkScord(strs)
print(NewStr)
except:
break