import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	}

} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	}

} Main public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	} main {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	} boolean flag = false; flag false int ans=0; ans 0 Scanner input = new Scanner(System.in); input new Scanner(System.in) int a= input.nextInt(); a input.nextInt() input.nextInt input int b= input.nextInt(); b input.nextInt() input.nextInt input for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		} int i =0; int i =0; i 0 i<Math.max(a, b) i Math.max(a, b) Math.max Math a b i++ i++ i {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		} {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		} if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			} Math.abs(a-i)==Math.abs(b-i) Math.abs(a-i) Math.abs Math a-i a i Math.abs(b-i) Math.abs Math b-i b i {
				flag = true;
				ans = i;
			} flag = true flag true ans = i ans i if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		} flag {System.out.println(ans);} System.out.println(ans) System.out.println System.out System System.out ans {
			 System.out.println("IMPOSSIBLE");
			
		} System.out.println("IMPOSSIBLE") System.out.println System.out System System.out "IMPOSSIBLE" String[] args args public class Main {

	public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	}

} public class Main {

	public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		boolean flag = false;
		int ans=0;
		Scanner input = new Scanner(System.in);
		int a= input.nextInt();
		int b= input.nextInt();
		
		for(int i =0;i<Math.max(a, b);i++) {
			if(Math.abs(a-i)==Math.abs(b-i)) {
				flag = true;
				ans = i;
			}
		}
		if(flag) {System.out.println(ans);}
		
		else {
			 System.out.println("IMPOSSIBLE");
			
		}
		
	
		

	}

}
