import java.util.*;

public class Main {
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	}
} import java.util.*; util.* java public class Main {
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	}
} Main public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	} main {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int a=scanner.nextInt(); a scanner.nextInt() scanner.nextInt scanner int b=scanner.nextInt(); b scanner.nextInt() scanner.nextInt scanner if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		} Math.abs(a-b)%2 == 1 Math.abs(a-b)%2 Math.abs(a-b) Math.abs Math a-b a b 2 1 System.out.println("IMPOSSIBLE") System.out.println System.out System System.out "IMPOSSIBLE" {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		} int sol=Math.abs(a-b) /2; sol Math.abs(a-b) /2 Math.abs(a-b) Math.abs Math a-b a b 2 System.out.println(Math.max(a, b) - sol) System.out.println System.out System System.out Math.max(a, b) - sol Math.max(a, b) Math.max Math a b sol scanner.close() scanner.close scanner String args[] args public class Main {
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	}
} public class Main {
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	}
} Main
import java.util.*;

public class Main {
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);

		int a=scanner.nextInt();
		int b=scanner.nextInt();
//		System.out.println("a=" + a);
//		System.out.println("b=" + b);

		if(Math.abs(a-b)%2 == 1) System.out.println("IMPOSSIBLE");
		else {
			int sol=Math.abs(a-b) /2;
			System.out.println(Math.max(a, b) - sol);
		}

		scanner.close();
	}
}
