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

public class Main {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    }
} 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 s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    }
} Main public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String s1 = br.readLine(); s1 br.readLine() br.readLine br String answer = ""; answer "" for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        } int c s1.toCharArray() s1.toCharArray s1 {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        } {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        } c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c c c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c c >= 65 && c <= 90 c >= 65 c 65 c <= 90 c 90 c + 32 c 32 c >= 97 && c <= 122 ? c - 32 : c c >= 97 && c <= 122 c >= 97 c 97 c <= 122 c 122 c - 32 c 32 c answer += (char) c answer (char) c System.out.println(answer) System.out.println System.out System System.out answer String[] args args public class Main {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    }
} public class Main {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    }
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s1 = br.readLine();
        String answer = "";
        for (int c : s1.toCharArray()) {
            c = c >= 65 && c <= 90 ? c + 32 : c >= 97 && c <= 122 ? c - 32 : c;
            answer += (char) c;
        }
        System.out.println(answer);
    }
}