Problem

4 /8


Crypto-resistant password. Built-in Methods

Theory Click to read/hide

String manipulation methods

Python has many methods (out-of-the-box functions) for working with strings.  Many of them are called using dot notation and are called methods. A complete list of string manipulation methods can be found online. 
Let's get acquainted with some of them. s = "aAbBcC" sUp = s.upper() # sUp = "AABBCC" - a method that translates   # uppercase each character of the string sLow = s.lower() # sLow = "aabbcc" - a method that translates   # lowercase each character of the string To the left of the dot is the name of the string (or the string itself in quotation marks) to which the method is to be applied, and to the right of the dot is the name of the method. The method is always written with parentheses. There can be any parameters inside the brackets if they are needed.

Previously, we already used the method of working with strings when we displayed data on the screen in a certain format - the format() method a = 4 b = 5 print("{}+{}={}".format(a,b,a+b)) # 4+5=9 Another useful method  isdigit() is a method to check if all characters of a string are digits, it returns a boolean value (True or False). s = "ab1c" print(s.isdigit()) #False s = "123" print(s.isdigit()) #True The useful strip() method allows you to remove spaces at the beginning and end of a string s = " ab 1c " print('s=', s.strip()) # s=ab 1c

Problem

A password is called strong if it includes both lowercase Latin letters and uppercase Latin letters and numbers, and its length must be at least 8 characters.
It is required to determine whether this password is cryptographically strong.

Input
One line is entered, consisting only of Latin letters and numbers. The number of characters per line does not exceed 100.

Imprint
Print the word YES if the specified password is strong, and NO – otherwise.
 
Examples
# Input Output
1 e NO
2 AAAbbb123 YES