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

public class Main {

	public static void main(String[] args) throws Exception {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    }

} 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 {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    }

} Main public static void main(String[] args) throws Exception {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    } main {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    } boolean first=true; first true try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        } {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)) BufferedReader br = new BufferedReader(new InputStreamReader(System.in)) new BufferedReader(new InputStreamReader(System.in)) String line; line int i=0 i 0 n=0 n 0 m=0 m 0 l=0; l 0 while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            } (line = br.readLine()) != null (line = br.readLine()) line br.readLine() br.readLine br null {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            } byte[] a=line.getBytes ("US-ASCII"); a line.getBytes ("US-ASCII") line.getBytes line "US-ASCII" for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	} int j=0; int j=0; j 0 j<a.length j a.length a a.length j++ j++ j {
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	} {
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	} if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		} a[j]<=90&&a[j]>=65 a[j]<=90 a[j] a j 90 a[j]>=65 a[j] a j 65 {
            			a[j]+=32;
            		} a[j]+=32 a[j] a j 32 if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		} a[j]<=122&&a[j]>=97 a[j]<=122 a[j] a j 122 a[j]>=97 a[j] a j 97 {
            			a[j]-=32;
            		} a[j]-=32 a[j] a j 32 System.out.println(new String(a,"US-ASCII")) System.out.println System.out System System.out new String(a,"US-ASCII") break; String[] args args public class Main {

	public static void main(String[] args) throws Exception {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    }

} public class Main {

	public static void main(String[] args) throws Exception {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    }

} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws Exception {
        // TODO ?????????????????????????????????????????????
        
        boolean first=true;
        try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
            String line;
            int i=0,n=0,m=0,l=0;
            while ((line = br.readLine()) != null) {
            	byte[] a=line.getBytes ("US-ASCII");
            	
            	for(int j=0;j<a.length;j++){
            		if(a[j]<=90&&a[j]>=65){
            			a[j]+=32;
            		}else if(a[j]<=122&&a[j]>=97){
            			a[j]-=32;
            		}
            	}
            	System.out.println(new String(a,"US-ASCII"));
            	break;
            }
        }
    }

}