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

public class Main {
	
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
} 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) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
} Main public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	} main {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	} try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		} catch (IOException e) {
			e.printStackTrace();
		} IOException e {
			e.printStackTrace();
		} e.printStackTrace() e.printStackTrace e {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); reader new BufferedReader(new InputStreamReader(System.in)) String input = reader.readLine(); input reader.readLine() reader.readLine reader char ch; ch for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			} int i = 0; int i = 0; i 0 i < input.length() i input.length() input.length input i++ i++ i {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			} {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			} ch = input.charAt(i) ch input.charAt(i) input.charAt input i if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				} Character.isUpperCase(ch) Character.isUpperCase Character ch {
					System.out.print(Character.toLowerCase(ch));
				} System.out.print(Character.toLowerCase(ch)) System.out.print System.out System System.out Character.toLowerCase(ch) Character.toLowerCase Character ch if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				} Character.isLowerCase(ch) Character.isLowerCase Character ch {
					System.out.print(Character.toUpperCase(ch));
				} System.out.print(Character.toUpperCase(ch)) System.out.print System.out System System.out Character.toUpperCase(ch) Character.toUpperCase Character ch {
					System.out.print(ch);
				} System.out.print(ch) System.out.print System.out System System.out ch System.out.println() System.out.println System.out System System.out String[] args args public class Main {
	
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
} public class Main {
	
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String input = reader.readLine();

			char ch;
			for (int i = 0; i < input.length(); i++) {
				ch = input.charAt(i);
				if (Character.isUpperCase(ch)) {
					System.out.print(Character.toLowerCase(ch));
				} else if (Character.isLowerCase(ch)){
					System.out.print(Character.toUpperCase(ch));
				} else {
					System.out.print(ch);
				}	
			}
			System.out.println();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
}