S=input() for s in S: print(chr(ord(s)+32*((-1)**(ord(s)>=97))),end="")