sWAP cASE

  • + 0 comments

    we can use the simple swapcase function to do it

    def swap_case(s):

    return s.swapcase()
    

    if name == 'main': s = input() result = swap_case(s) print(result)