import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
 
    public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
 
    public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    }
} Main public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    } main {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String str = br.readLine(); str br.readLine() br.readLine br char[] cArray = str.toCharArray(); cArray str.toCharArray() str.toCharArray str int len = cArray.length; len cArray.length cArray cArray.length for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	} int i = 0; int i = 0; i 0 i < len i len i++ i++ i {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	} {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	} int b = (int)Character.toString(cArray[i]).getBytes()[0]; b (int)Character.toString(cArray[i]).getBytes()[0] Character.toString(cArray[i]).getBytes() Character.toString(cArray[i]).getBytes Character.toString(cArray[i]) Character.toString Character cArray[i] cArray i 0 if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		} b >= 65 & b <= 90 b >= 65 b 65 b <= 90 b 90 {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} cArray[i] = Character.toLowerCase(cArray[i]) cArray[i] cArray i Character.toLowerCase(cArray[i]) Character.toLowerCase Character cArray[i] cArray i if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		} b >= 97 & b <= 122 b >= 97 b 97 b <= 122 b 122 {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		} cArray[i] = Character.toUpperCase(cArray[i]) cArray[i] cArray i Character.toUpperCase(cArray[i]) Character.toUpperCase Character cArray[i] cArray i System.out.println(new String(cArray)) System.out.println System.out System System.out new String(cArray) String[] args args public class Main {
 
    public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    }
} public class Main {
 
    public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
 
    public static void main(String[] args) throws Exception {
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	String str = br.readLine();
    	char[] cArray = str.toCharArray();
    	int len = cArray.length;
    	for (int i = 0; i < len; i++) {
    		int b = (int)Character.toString(cArray[i]).getBytes()[0];
    		if (b >= 65 & b <= 90) {
    			cArray[i] = Character.toLowerCase(cArray[i]);
    		} else if (b >= 97 & b <= 122) {
    			cArray[i] = Character.toUpperCase(cArray[i]);
    		}
    	}
    	System.out.println(new String(cArray));
    }
}