import java.util.Scanner; class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); String str = sc.next(); char[] c = str.toCharArray(); for(char ch:c) { if(Character.isLowerCase(ch)) { System.out.print(Character.toUpperCase(ch)); }else if(Character.isUpperCase(ch)) { System.out.print(Character.toLowerCase(ch)); } } System.out.println(""); } }