We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
s=input()
alpha="False"
alphe="False"
digit="False"
lower="False"
upper="False"
for i in s:
if i.isalnum()==True:
alpha="True"
if i.isalpha()==True:
alphe="True"
if i.isdigit()==True:
digit="True"
if i.islower()==True:
lower="True"
if i.isupper()==True:
upper="True"
print(alpha)
print(alphe)
print(digit)
print(lower)
print(upper)
String Validators
You are viewing a single comment's thread. Return to all comments →
s=input() alpha="False" alphe="False" digit="False" lower="False" upper="False" for i in s: if i.isalnum()==True: alpha="True" if i.isalpha()==True: alphe="True" if i.isdigit()==True: digit="True" if i.islower()==True: lower="True" if i.isupper()==True: upper="True" print(alpha) print(alphe) print(digit) print(lower) print(upper)