import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	} main {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int a=scan.nextInt(); a scan.nextInt() scan.nextInt scan int b=scan.nextInt(); b scan.nextInt() scan.nextInt scan if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		} (a-b)%2==0 (a-b)%2 (a-b) a b 2 0 {
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		} if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			} a<b a b {
				System.out.println((b-a)/2+a);
			} System.out.println((b-a)/2+a) System.out.println System.out System System.out (b-a)/2+a (b-a)/2 (b-a) b a 2 a {
				System.out.println((a-b)/2+b);
			} System.out.println((a-b)/2+b) System.out.println System.out System System.out (a-b)/2+b (a-b)/2 (a-b) a b 2 b {
			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) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int a=scan.nextInt();
		int b=scan.nextInt();
		if((a-b)%2==0){
			if(a<b){
				System.out.println((b-a)/2+a);
			}else{
				System.out.println((a-b)/2+b);
			}
		}else{
			System.out.println("IMPOSSIBLE");
		}
	}
}