import java.util.*;
public class Main{
public static void main(String args[])
{
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

}
} import java.util.*; util.* java public class Main{
public static void main(String args[])
{
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

}
} Main public static void main(String args[])
{
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

} main {
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

} Scanner sp=new Scanner(System.in); sp new Scanner(System.in) int a=sp.nextInt(); a sp.nextInt() sp.nextInt sp int b=sp.nextInt(); b sp.nextInt() sp.nextInt sp int l=0; l 0 int n=0; n 0 if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    } a<b a b {
        l=b;
    } l=b l b {
        l=a;
    } l=a l a for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   } int k=0; int k=0; k 0 k<l k l k++ k++ k {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   } {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   } if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       } 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 {
           n=k;
       } n=k n k if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   } !(n==0) (n==0) n 0 {
       System.out.println(n);
   } System.out.println(n) System.out.println System.out System System.out n {
       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 sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

}
} public class Main{
public static void main(String args[])
{
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

}
} Main
import java.util.*;
public class Main{
public static void main(String args[])
{
  Scanner sp=new Scanner(System.in);
   int a=sp.nextInt();
    int b=sp.nextInt();
    int l=0;
     int n=0;
    if(a<b)
    {
        l=b;
    }
    else
    {
        l=a;
    }
   for(int k=0;k<l;k++)
   {
      if(Math.abs(a-k)==Math.abs(b-k))
       {
           n=k;
       }
      
   }
   if(!(n==0))
   {
       System.out.println(n);
   }
   else{
       System.out.println("IMPOSSIBLE");
   }
   
   

}
}
