import java.io.*;
 
class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringBuilder res = new StringBuilder();
        String line = br.readLine();
        int len = line.length();
        for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        }
        System.out.println(res);
    }
} import java.io.*; io.* java class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringBuilder res = new StringBuilder();
        String line = br.readLine();
        int len = line.length();
        for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        }
        System.out.println(res);
    }
} Main public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringBuilder res = new StringBuilder();
        String line = br.readLine();
        int len = line.length();
        for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        }
        System.out.println(res);
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringBuilder res = new StringBuilder();
        String line = br.readLine();
        int len = line.length();
        for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        }
        System.out.println(res);
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) StringBuilder res = new StringBuilder(); res new StringBuilder() String line = br.readLine(); line br.readLine() br.readLine br int len = line.length(); len line.length() line.length line for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        } int i=0; int i=0; i 0 i<len i len i++ i++ i {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        } {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        } char ch = line.charAt(i); ch line.charAt(i) line.charAt line i if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch); Character.isLowerCase(ch) Character.isLowerCase Character ch res.append(Character.toUpperCase(ch)) res.append res Character.toUpperCase(ch) Character.toUpperCase Character ch if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch); Character.isUpperCase(ch) Character.isUpperCase Character ch res.append(Character.toLowerCase(ch)) res.append res Character.toLowerCase(ch) Character.toLowerCase Character ch res.append(ch) res.append res ch System.out.println(res) System.out.println System.out System System.out res String[] args args
import java.io.*;
 
class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringBuilder res = new StringBuilder();
        String line = br.readLine();
        int len = line.length();
        for(int i=0; i<len; i++) {
            char ch = line.charAt(i);
            if(Character.isLowerCase(ch)) res.append(Character.toUpperCase(ch));
            else if(Character.isUpperCase(ch)) res.append(Character.toLowerCase(ch));
            else res.append(ch);
        }
        System.out.println(res);
    }
}