String Validators

  • + 0 comments

    Here is my completely overengineered Solution for you:

    import re

    if name == 'main': s = input() m = re.search(r'(?=(.\w)?)(?=(.[A-Za-z])?)(?=(.\d)?)(?=(.[a-z])?)(?=(.*[A-Z])?)', s) print('\n'.join([str(bool(group)) for group in m.groups()]))