Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- >>> def hasNumbers(inputString):
- ... return any(char.isdigit() for char in inputString)
- >>> def hasChar(inputString):
- ... return any(char.isalpha() for char in inputString)
- if(hasNumbers("Charlie123") and hasChar("Charlie123"))
Add Comment
Please, Sign In to add comment