
import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	}
}
 import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	} main {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) long A = sc.nextInt(); A sc.nextInt() sc.nextInt sc long B = sc.nextInt(); B sc.nextInt() sc.nextInt sc if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		} (A+B)%2!=0 (A+B)%2 (A+B) A B 2 0 {
			System.out.println("IMPOSSIBLE");
			return;
		} System.out.println("IMPOSSIBLE") System.out.println System.out System System.out "IMPOSSIBLE" return; if(A==B) {
			System.out.println(1);
			return;
		} A==B A B {
			System.out.println(1);
			return;
		} System.out.println(1) System.out.println System.out System System.out 1 return; System.out.println((A+B)/2) System.out.println System.out System System.out (A+B)/2 (A+B) A B 2 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	}
} Main

import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long A = sc.nextInt();
		long B = sc.nextInt();
		
		if((A+B)%2!=0) {
			System.out.println("IMPOSSIBLE");
			return;
		}
		if(A==B) {
			System.out.println(1);
			return;
		}
		System.out.println((A+B)/2);
		
	}
}

