import java.io.*;
import java.util.Arrays;
import java.util.Scanner;

public class Main{
	public static void main(String[] args){ 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	}
} import java.io.*; io.* java import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main{
	public static void main(String[] args){ 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	}
} Main public static void main(String[] args){ 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	} main { 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String str = sc.nextLine(); str sc.nextLine() sc.nextLine sc char[] let = str.toCharArray(); let str.toCharArray() str.toCharArray str for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		} int i = 0 ; int i = 0 ; i 0 i<let.length i let.length let let.length i ++ i ++ i {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		} {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		} if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			} Character.isUpperCase(let[i]) Character.isUpperCase Character let[i] let i {
				let[i] = Character.toLowerCase(let[i]);
			} let[i] = Character.toLowerCase(let[i]) let[i] let i Character.toLowerCase(let[i]) Character.toLowerCase Character let[i] let i {
				let[i] = Character.toUpperCase(let[i]);
			} let[i] = Character.toUpperCase(let[i]) let[i] let i Character.toUpperCase(let[i]) Character.toUpperCase Character let[i] let i System.out.print(let[i]) System.out.print System.out System System.out let[i] let i System.out.println("") System.out.println System.out System System.out "" String[] args args public class Main{
	public static void main(String[] args){ 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	}
} public class Main{
	public static void main(String[] args){ 
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		char[] let = str.toCharArray();
		for (int i = 0 ; i<let.length ; i ++ ) {
			if (Character.isUpperCase(let[i])) {
				let[i] = Character.toLowerCase(let[i]);
			}else{
				let[i] = Character.toUpperCase(let[i]);
			}
			System.out.print(let[i]);
		}
		System.out.println("");
	}
} Main
import java.io.*;
import java.util.Arrays;
import java.util.Scanner;

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