import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	}	

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

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	}	

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc boolean isBothNumberMenus = true; isBothNumberMenus true int index = 1; index 1 while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		} isBothNumberMenus {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		} if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			} a - index < 0 && b - index < 0 a - index < 0 a - index a index 0 b - index < 0 b - index b index 0 {
				System.out.println("IMPOSSIBLE");
				break;
			} System.out.println("IMPOSSIBLE") System.out.println System.out System System.out "IMPOSSIBLE" break; if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			} Math.abs(a - index) == Math.abs(b - index) Math.abs(a - index) Math.abs Math a - index a index Math.abs(b - index) Math.abs Math b - index b index {
				System.out.println(index);
				break;
			} System.out.println(index) System.out.println System.out System System.out index break; index++ index String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	}	

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	}	

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		boolean isBothNumberMenus = true;
		int index = 1;
		while(isBothNumberMenus) {
			if(a - index < 0 && b - index < 0) {
				System.out.println("IMPOSSIBLE");
				break;
			}
			
			if(Math.abs(a - index) == Math.abs(b - index)) {
				System.out.println(index);
				break;
			}
			index++;
			
		}
		

		
		

		
		
	}	

}