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

// (1) ????????????1???????????????
// (2) ?????????????????????????????§????????¨?°??????????????????????????????????????´????????????°result???????????????
// (3) ????????????????????????????????\?????????????????????
	// (3.1) ????????????????????§??????????????\?????????????????????
		// (3.1.1) ?°?????????????????????????result???????´???????
	// (3.2) ???????????????????°???????????????\?????????????????????
		// (3.2.1) ??§????????????????????????result???????´???????
	// (3.3)???????????¢????????????????????\???????????\?????????????????????
		// (3.3.1) ??????????????????result???????´???????
// (4) result?????¨?????????


public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	}
} Main public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	} main {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	} BufferedReader br = new BufferedReader (new InputStreamReader (System.in)); br new BufferedReader (new InputStreamReader (System.in)) String textInput = br.readLine(); textInput br.readLine() br.readLine br String result = ""; result "" for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		} int i = 0; int i = 0; i 0 i < textInput.length() i textInput.length() textInput.length textInput i++ i++ i {
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		} {
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		} if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			} Character.isUpperCase(textInput.charAt(i)) Character.isUpperCase Character textInput.charAt(i) textInput.charAt textInput i {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			} char textInputChar = textInput.charAt(i); textInputChar textInput.charAt(i) textInput.charAt textInput i char textOutputLo = Character.toLowerCase(textInputChar); textOutputLo Character.toLowerCase(textInputChar) Character.toLowerCase Character textInputChar String strLo = String.valueOf(textOutputLo); strLo String.valueOf(textOutputLo) String.valueOf String textOutputLo result += strLo result strLo if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			} Character.isLowerCase(textInput.charAt(i)) Character.isLowerCase Character textInput.charAt(i) textInput.charAt textInput i {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			} char textInputChar = textInput.charAt(i); textInputChar textInput.charAt(i) textInput.charAt textInput i char textOutputUp = Character.toUpperCase(textInputChar); textOutputUp Character.toUpperCase(textInputChar) Character.toUpperCase Character textInputChar String strUp = String.valueOf(textOutputUp); strUp String.valueOf(textOutputUp) String.valueOf String textOutputUp result += strUp result strUp {
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			} String strLet = String.valueOf(textInput.charAt(i)); strLet String.valueOf(textInput.charAt(i)) String.valueOf String textInput.charAt(i) textInput.charAt textInput i result += strLet result strLet System.out.println(result) System.out.println System.out System System.out result String[] args args public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

// (1) ????????????1???????????????
// (2) ?????????????????????????????§????????¨?°??????????????????????????????????????´????????????°result???????????????
// (3) ????????????????????????????????\?????????????????????
	// (3.1) ????????????????????§??????????????\?????????????????????
		// (3.1.1) ?°?????????????????????????result???????´???????
	// (3.2) ???????????????????°???????????????\?????????????????????
		// (3.2.1) ??§????????????????????????result???????´???????
	// (3.3)???????????¢????????????????????\???????????\?????????????????????
		// (3.3.1) ??????????????????result???????´???????
// (4) result?????¨?????????


public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader (new InputStreamReader (System.in));
		String textInput = br.readLine();
		String result = "";

		for (int i = 0;i < textInput.length(); i++){
			if (Character.isUpperCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputLo = Character.toLowerCase(textInputChar);
				String strLo = String.valueOf(textOutputLo);
				result += strLo;
			}
			else if (Character.isLowerCase(textInput.charAt(i))) {
				char textInputChar = textInput.charAt(i);
				char textOutputUp = Character.toUpperCase(textInputChar);
				String strUp = String.valueOf(textOutputUp);
				result += strUp;
			}
			else{
				String strLet = String.valueOf(textInput.charAt(i));
				result += strLet;
			}
		}
		System.out.println(result);
	}
}