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();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	}
} 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();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	}
} Main public static void main(String[] args){

		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	} main {

		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	} 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 int k; k if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		} a==b a b {
			System.out.println("0");
		} System.out.println("0") System.out.println System.out System System.out "0" {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		} if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			} a%2==b%2 a%2 a 2 b%2 b 2 {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			} k=(a+b)/2 k (a+b)/2 (a+b) a b 2 if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				} (a-k<0&&b-k>0)||(a-k>0&&b-k<0) (a-k<0&&b-k>0) a-k<0 a-k a k 0 b-k>0 b-k b k 0 (a-k>0&&b-k<0) a-k>0 a-k a k 0 b-k<0 b-k b k 0 {
					System.out.println(k);
				} System.out.println(k) System.out.println System.out System System.out k {
				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 sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	}
} public class Main {
	public static void main(String[] args){

		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	}
} 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();

		int k;

		if(a==b) {
			System.out.println("0");
		}else {
			if(a%2==b%2) {
				k=(a+b)/2;
				if((a-k<0&&b-k>0)||(a-k>0&&b-k<0)) {
					System.out.println(k);
				}
			}else {
				System.out.println("IMPOSSIBLE");
			}
		}
	}
}
