import java.util.Scanner;

public class Main {

	private static Scanner sc;

	public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	}
} import java.util.Scanner; Scanner java.util public class Main {

	private static Scanner sc;

	public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	}
} Main private static Scanner sc; sc public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	} main {
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	} sc = new Scanner(System.in) sc new Scanner(System.in) String line = sc.nextLine(); line sc.nextLine() sc.nextLine sc for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		} int i=0; int i=0; i 0 i<line.length() i line.length() line.length line i++ i++ i {
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		} {
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		} if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i))); Character.isLowerCase(line.charAt(i)) Character.isLowerCase Character line.charAt(i) line.charAt line i {
				System.out.print(Character.toUpperCase(line.charAt(i)));
			} System.out.print(Character.toUpperCase(line.charAt(i))) System.out.print System.out System System.out Character.toUpperCase(line.charAt(i)) Character.toUpperCase Character line.charAt(i) line.charAt line i System.out.print(Character.toLowerCase(line.charAt(i))) System.out.print System.out System System.out Character.toLowerCase(line.charAt(i)) Character.toLowerCase Character line.charAt(i) line.charAt line i System.out.println() System.out.println System.out System System.out String[] args args public class Main {

	private static Scanner sc;

	public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	}
} public class Main {

	private static Scanner sc;

	public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	}
} Main
import java.util.Scanner;

public class Main {

	private static Scanner sc;

	public static void main(String[] args){
		sc = new Scanner(System.in);
		String line = sc.nextLine();
		for(int i=0;i<line.length();i++){
			if(Character.isLowerCase(line.charAt(i))){
				System.out.print(Character.toUpperCase(line.charAt(i)));
			}else System.out.print(Character.toLowerCase(line.charAt(i)));
		}
		System.out.println();
	}
}