import java.util.Scanner;

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

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        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 in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  }
} Main public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  } main {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  } Scanner in = new Scanner(System.in); in new Scanner(System.in) while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    } in.hasNext() in.hasNext in {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    } int A = in.nextInt(); A in.nextInt() in.nextInt in int B = in.nextInt(); B in.nextInt() in.nextInt in int K = Math.min(A, B) + Math.abs(A - B) / 2; K Math.min(A, B) + Math.abs(A - B) / 2 Math.min(A, B) Math.min Math A B Math.abs(A - B) / 2 Math.abs(A - B) Math.abs Math A - B A B 2 if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      } Math.abs(A - K) == Math.abs(B - K) Math.abs(A - K) Math.abs Math A - K A K Math.abs(B - K) Math.abs Math B - K B K {
        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 in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  }
} public class Main {
  public static void main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  }
} Main
import java.util.Scanner;

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

    while (in.hasNext()) {
      int A = in.nextInt();
      int B = in.nextInt();
      int K = Math.min(A, B) + Math.abs(A - B) / 2;

      if (Math.abs(A - K) == Math.abs(B - K)) {
        System.out.println(K);
      } else {
        System.out.println("IMPOSSIBLE");
      }
    }
  }
}