Problem:
 Score: 100 points    Problem Statement We have two distinct integers A and B .  Print the integer K such that |A - K| = |B - K| .  If such an integer does not exist, print IMPOSSIBLE instead.      Constraints  All values in input are integers.  0 \leq A,\ B \leq 10^9  A and B are distinct.         Input Input is given from Standard Input in the following format:  A  B       Output Print the integer K satisfying the condition.  If such an integer does not exist, print IMPOSSIBLE instead.        Sample Input 1 2 16      Sample Output 1 9  |2 - 9| = 7 and |16 - 9| = 7 , so 9 satisfies the condition.       Sample Input 2 0 3      Sample Output 2 IMPOSSIBLE  No integer satisfies the condition.       Sample Input 3 998244353 99824435      Sample Output 3 549034394

Solution (Python):
a, b = map(int, input().split())

s = a + b
if s % 2 != 0:
    print("IMPOSSIBLE")
else:
    print(s // 2)

Solution (Python):
ab = list(map(int, input().split()))
a = ab[0]
b = ab[1]

ans = "IMPOSSIBLE"

if (a+b)%2 == 0:
	ans = int((a+b)/2)
print(ans)

Solution (Python):
A,B = map(int,input().split())

K = (A+B)% 2
if K == 0:
    print(int((A+B)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
A,B =map(int,input().split())

if (A+B)%2 ==0:
    print(int((A+B)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b = map(int,input().split())


if (a+b) % 2 == 0:
    print((a+b)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b = map(int,input().split())

 
if (a+b)%2==0:
    print((a+b)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
import sys
a, b = map(int, input().split(' '))

ans = 0

total = a + b

if total % 2 == 1:
  print('IMPOSSIBLE')
  sys.exit()

ans = total // 2

print(ans)

Solution (Python):
a,b = map(int,input().split())
print((a+b)//2 if (a+b)%2 == 0 or a == b else "IMPOSSIBLE")

Solution (Python):
A,B = map(int,input().split())
if A % 2 == B % 2 :
    print((A+B)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b =map(int,input().split())
if a%2==b%2:
  print((a+b)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
 
if a % 2 == b % 2:
  print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())

if A%2 != B%2:
  print("IMPOSSIBLE")
else:
  print((A+B)//2)

Solution (Python):
a, b = map(int, input().split())
k = (a + b)//2
if abs(a - k) == abs(b - k):
        print(k)
else:
        print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a+b)%2!=0:
	print('IMPOSSIBLE')
else:
	print((a+b)//2)

Solution (Python):
A,B=map(int,input().split())
print(int((A+B)/2) if abs(A-int((A+B)/2))==abs(B-int((A+B)/2)) else'IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
print("IMPOSSIBLE" if (a+b)%2==1else ((a+b)//2))

Solution (Python):
a, b=map(int, input().split())
if (a+b)%2==0:
  print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b=map(int, input().split())
print("IMPOSSIBLE" if (a+b)%2 else (a+b)//2)

Solution (Python):
ab = list(map(int,input().split(' ')))
ans = sum(ab)/2
if ans.is_integer():
    print(int(ans))
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())

if a % 2 != b % 2:
  print('IMPOSSIBLE')
else:
  print((a + b) // 2)

Solution (Python):
a,b=map(int, input().split())
if (a+b)%2==0:
    print(int((a+b)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if abs(a-b) % 2 != 0:
    print('IMPOSSIBLE')
else:
    print(abs(a-b) // 2 + min(a, b))

Solution (Python):
a,b = map(int, input().split())

if (a + b) % 2 != 0:
    ans = 'IMPOSSIBLE'
else:
    ans = (a + b) // 2

print(ans)

Solution (Python):
a,b = list(map(int, input().split()))
if (a+b)%2==0:
    print((a+b)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):


A,B=map(int,input().split())

if (A+B)/2==(A+B)//2:
    print((A+B)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):

import sys

import math








def main():
    a, b = [int(x) for x in sys.stdin.readline().split()]
    if abs(a) == abs(b):
        ans = 0
    else:
        ans = (a + b) / 2
    
    print(int(ans) if ans == math.floor(ans) else 'IMPOSSIBLE')


if __name__ == "__main__":
    main()

Solution (Python):
A, B = [int(n) for n in input().split()]
print('IMPOSSIBLE' if (A+B)%2 else (A+B)//2)

Solution (Python):
from collections import defaultdict,deque, Counter
import sys,heapq,bisect,math,itertools,string,queue,copy,time
import numpy as np
sys.setrecursionlimit(10**8)
INF = float('inf')
mod = 10**9+7
eps = 10**-7
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))
def inpl_str(): return list(sys.stdin.readline().split())

[A,B] = inpl()
print((A+B)//2 if (A+B)%2 ==0 else 'IMPOSSIBLE')

Solution (Python):
a,b=list(map(int,input().split()))

if (a+b)%2==0:
    print((a+b)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())

if (a + b) % 2 == 0:
    print((a + b) // 2)

else:
    print("IMPOSSIBLE")

Solution (Python):
a,b=map(int, input().split())
if (a+b)%2==0:
  print(int((a+b)//2))
else:
  print('IMPOSSIBLE')

Solution (Python):
A,B=map(int,input().split(' '))
if (A+B)%2:
  print("IMPOSSIBLE")
else:
  print((A+B)//2)

Solution (Python):
a,b=map(int,input().split())
if (a+b)//2==(a+b)/2:
    print((a+b)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):

import sys
def input():
    return sys.stdin.readline().rstrip()

def main():
    A, B = map(int, input().split())

    if (A+B)%2:
        print("IMPOSSIBLE")
    else:
        print((A+B)//2)


if __name__ == '__main__':
    main()

Solution (Python):
import sys
input = sys.stdin.readline
def print_ans(A, B):
    """Test Case
    >>> print_ans(2, 16)
    9
    >>> print_ans(0, 3)
    IMPOSSIBLE
    >>> print_ans(998244353, 99824435)
    549034394
    """
    if (A + B) % 2 == 0:
        print((A + B) // 2)
    else:
        print("IMPOSSIBLE")

if __name__ == '__main__':
    A, B= map(int,input().rstrip().split())
    print_ans(A, B)

Solution (Python):
a, b = map(int,input().split())
s = a+b
if s%2==0:
    print(s//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A, B = map(int,input().split())
K = A+B
if K%2==0:
    print(K//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B=map(int,input().split())
K=A+B
if K%2==0:
    K=int(K/2)
else:
    K='IMPOSSIBLE'

print(K)

Solution (Python):
A , B = map( int , input() . split() )

w = ( A + B )

if w % 2 == 0:
    print(int( w / 2 ))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b = map(int, input().split())
if (a+b)%2==1:
    print("IMPOSSIBLE")
else:
    print(int((a+b)/2))

Solution (Python):
A,B = (int(i) for i in input().split())

if (A + B) % 2 == 0:
	print(int((A + B) / 2))
else:
	print('IMPOSSIBLE')

Solution (Python):
i = list(map(int, input().split()))
if (i[0] - i[1]) % 2 == 0:
  print(min(i[0],i[1]) + abs(i[0] - i[1]) // 2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
if a == b:
    print(0)
elif (a+b)%2 == 0:
    print((a+b)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())
if A == B:
    print(0)
elif (A + B) % 2 == 0:
    print((A + B) // 2)
else:
    print("IMPOSSIBLE")

Solution (Python):
def solve():
    A, B = map(int, input().split())

    if (B - A) % 2 != 0:
        print('IMPOSSIBLE')
        exit()
    else:
        print((B + A) // 2)


if __name__ == '__main__':
    solve()

Solution (Python):
A, B = map(int, input().split())
C = int((A + B) / 2)
if (C * 2 == A + B):
    print(C)
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int,input().split())

if (a + b) % 2 == 0:
    c = (a + b) // 2
else:
    c = 'IMPOSSIBLE'

print(c)

Solution (Python):
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b



def sum_of_arithmetic_progression(s, d, n):
    return n * (2 * s + (n - 1) * d) // 2



def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)



def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


def main():
    A, B = map(int, input().split())
    k = abs(A - B)
    if k % 2 != 0:
        print("IMPOSSIBLE")
    else:
        print(min(A, B) + (k // 2))


if __name__ == '__main__':
    main()

Solution (Python):
n,m=map(int,input().split())
if (n-m)%2==0:
  print(min(n,m)+abs(n-m)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())

if (a + b) % 2 == 1:
    print("IMPOSSIBLE")
else:
    print((a+b)//2)

Solution (Python):
A, B = map(int, input().split())
K = (A + B) / 2
L = (A + B) // 2
if K.is_integer():
  print(L)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b = map(int, input().split())

k = (a+b)/2




if k.is_integer() :
	print(int(k))
else:
	print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
print((a+b)//2 if (a+b)%2 == 0 else 'IMPOSSIBLE')

Solution (Python):
a,b,=map(int, input().split())
test = (a+b)%2
ans = (a+b)/2
if test == 0:
    print(int(ans))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int, input().split())
if (a+b)%2==0:
	print((a+b)//2)
else:
	print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())

if (a + b) % 2 == 0:
    print(int((a + b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())

if (a+b) % 2 == 0:
    res = (a+b) // 2
else:
    res ='IMPOSSIBLE'
        
print(res)

Solution (Python):
x=list(input().split())
A=int(x[0])
B=int(x[1])
k=(A+B)/2
if int(k)==k:
     print("%.0f"%k)
else:
     print("IMPOSSIBLE")

Solution (Python):
a, b  = map(int,input().split())
print('IMPOSSIBLE' if (a+b)%2 else abs((a+b)//2))

Solution (Python):
a,b=map(int,input().split())
if (a+b)%2 ==0:print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
import sys
sys.setrecursionlimit(2147483647)
INF=float("inf")
MOD=10**9+7
input=lambda :sys.stdin.readline().rstrip()
def resolve():
    a,b=map(int,input().split())
    if((a+b)%2):
        print("IMPOSSIBLE")
    else:
        print((a+b)//2)
resolve()

Solution (Python):
A, B = map(int, input().split())

if (A + B) % 2 == 0: print((A + B)//2)
else:print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split(" "))
if a%2 != b%2:
    print("IMPOSSIBLE")
else:
    print(int((a+b)/2))

Solution (Python):
A,B = map(int, input().split())
if (A+B) % 2 == 0:
  print((A+B)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):

a, b = [int(s) for s in input().split()]
print((a + b) // 2 if (a + b) % 2 == 0 else 'IMPOSSIBLE')

Solution (Python):
a,b = map(int,(input().split()))
if (a+b)%2==1:
    print('IMPOSSIBLE')
else:
    print(int((a+b)/2))

Solution (Python):




a,b = map(int,input().split())

if (a+b)%2 == 1:
    print("IMPOSSIBLE")
else:
    print(max(a,b) - (abs(b-a) // 2))

Solution (Python):
A,B = map( int, input().split() )
if B > A:
    t = A
    A = B
    B = t
if ( B - A ) % 2 == 0:
    c = int( ( B - A ) / 2 )
    print( A + c )
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
if (a + b)%2 == 0:
  print((a+b)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b = map(int,input().split())
if (a-b)%2==0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = list(map(int, input().split()))

if ((a + b) % 2 == 0):
    print((a + b) // 2)
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
if (a+b)%2==0:
  print(int((a+b)/2))
else:
  print("IMPOSSIBLE")

Solution (Python):
A, B = list(map(int, input().split()))

if (A+B) % 2 == 0:
    print((A+B)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
if (a+b)%2==0:
  print((a+b)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
if a%2 == b%2:
  print((a+b)//2)

else:
  print("IMPOSSIBLE")

Solution (Python):

import sys

NO = "IMPOSSIBLE"  


def solve(A: int, B: int):
    if (A + B) % 2 == 0:
        print((A + B) // 2)
    else:
        print(NO)
    return



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)

if __name__ == '__main__':
    main()

Solution (Python):
A, B = map(int, input().split())

if (A + B) % 2 == 1:
    print('IMPOSSIBLE')
else:
    print((A + B) // 2)

Solution (Python):
A , B = map(int , input().split())





K = (A + B) / 2


if K % 1 == 0:
    print(int(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
A , B = map(int , input().split())

K = (A + B) / 2

if K % 1 == 0:
    print(int(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B = map(int,input().split())
if (A + B) % 2 == 0:
  print(int((A + B) / 2))
else:
  print('IMPOSSIBLE')

Solution (Python):
A,B = map(int,input().split())
if (A + B) % 2 == 0:
  print((A + B) // 2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
k=(a+b)/2

if k%1==0:
  print(int(k))

else:
  print('IMPOSSIBLE')

Solution (Python):
ab = list(map(int, input().split()))

k = int((ab[0] + ab[1]) /2)

if abs(ab[0] - k) == (abs(ab[1] - k)):
    print(int(k))
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B = input().split()
A,B  = int(A),int(B)

if((A+B)%2==0):
    print(int((A+B)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())
K = (A + B)/2
if K == int(K):
  print(int(K))
else:
  print('IMPOSSIBLE')

Solution (Python):
import unittest


class TestA(unittest.TestCase):
    def test_1(self):
        self.assertEqual(think(2, 16), '9')

    def test_2(self):
        self.assertEqual(think(0, 3), 'IMPOSSIBLE')

    def test_3(self):
        self.assertEqual(think(998244353, 99824435), '549034394')


def solve():
    a, b = read()
    result = think(a, b)
    write(result)


def read():
    return read_int(2)


def read_int(n):
    return list(map(lambda x: int(x), read_line().split(' ')))[:n]


def read_float(n):
    return list(map(lambda x: float(x), read_line().split(' ')))[:n]


def read_line(n=0):
    if n == 0:
        return input().rstrip()
    else:
        return input().rstrip()[:n]


def think(a, b):
    if abs(a - b) % 2 == 0:
        return str(min(a, b) + abs(a - b) // 2)
    return 'IMPOSSIBLE'


def write(result):
    print(result)


if __name__ == '__main__':
    
    solve()

Solution (Python):
A, B = map(int, input().split())
if (A + B) % 2 == 0:
    print(str(int((A + B) / 2)))
else:
    print('IMPOSSIBLE')

Solution (Python):
tmp = list(map(int, input().split()))
a = tmp[0]
b = tmp[1]

if (a + b) % 2 == 1:
  print ('IMPOSSIBLE')
else:
  print((a+b)//2)

Solution (Python):
a,b=map(int,input().split(" "))
if (a%2==0 and b%2==1) or (a%2==1 and b%2==0):
    print("IMPOSSIBLE") 
else:
    print(int((a+b)/2))

Solution (Python):
a, b = map(int, input().split())
if a%2 ==b%2:
  print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b = map(int, input().split())
if abs(a-b) % 2 == 0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
ave = int((a + b) / 2)
if a % 2 != b % 2:
    print("IMPOSSIBLE")
else:
    print(ave)

Solution (Python):
a, b = map(int, input().split())
ans = a+b

print(round(ans/2) if ans % 2 == 0 else 'IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
c=a+b
if c%2==0:
  print(int(c/2))
else:
  print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())

if (a + b) % 2 == 0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
if (a+b) % 2 !=0:
  print("IMPOSSIBLE")
else:
  print(int((a+b)/2))

Solution (Python):

def main():
    A, B = map(int, input().split())
    flg = (A + B) % 2 == 0
    print((A + B) // 2 if flg else "IMPOSSIBLE")


if __name__ == "__main__":
    main()

Solution (Python):
A, B = map(int, input().split())
if A % 2 == B % 2:
	print((A + B) // 2)
else:
	print("IMPOSSIBLE")

Solution (Python):
a,b = input().split()
a=int(a)
b=int(b)

if (a+b)%2 ==0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
s = list(map(int, input().split()))
A = s[0]
B = s[1]
result = abs(A - B)
if result % 2 ==0:
    print(int(min(A,B) + result/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = (int(_) for _ in input().split())
n = a + b
print(n // 2 if n % 2 == 0 else 'IMPOSSIBLE')

Solution (Python):
A,B = list(map(int,input().split()))
if (A+B)%2==1:
  print('IMPOSSIBLE')
else:
  print((A+B)//2)

Solution (Python):
A,B=map(int,input().split())

if (A+B)%2==0:
    print((A+B)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a + b) % 2 == 0:
  n = int((a + b) / 2)
else:
  n = 'IMPOSSIBLE'
print(n)

Solution (Python):
a,b = map(int,input().split())

if (a+b) % 2 == 0:
    print((a+b)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if ( a-b ) % 2 == 1:
    print('IMPOSSIBLE')
else:
    print( int( (a+b)/2 ) )

Solution (Python):
A, B = map(int, input().split())
if ( A + B ) % 2 == 0:
    print(int(( A + B ) / 2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())

if (a+b)%2 == 0:
    print(int((a+b)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b = map(int,input().split())
if(a>b):
    a,b = b,a

if((b-a)%2==0):
    print(a + (b-a)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B = map(int,input().split())
"""
answer = (A + B) // 2
print(answer)
if A + B % 2 == 0:
    print(A+B/2)
else:
    print("IMPOSSIBLE")
"""

if (A + B) % 2 == 0:
    print((A+B)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B=map(int,input().split())
if (A+B)%2==0:
    print((A+B)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):

a, b = map(int, input().split())
if (a-b)%2 == 1:
    print('IMPOSSIBLE')
else:
    print(min(a,b)+max(a-b,b-a)//2)

Solution (Python):
A,B = [int(i) for i in input().split(' ')]

0<=A
B<=10**9

if (A+B)%2 == 0:
  print((A+B)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A,B = [int(i) for i in input().split(' ')]

0<=A
B<=10**9

if (A+B)%2 == 0:
  print((A+B)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
if (a+b)%2:
  print("IMPOSSIBLE")
else:
  print((a+b)//2)

Solution (Python):
a,b=map(int,input().split())
print(int((a+b)/2)) if (a+b)%2==0 else print("IMPOSSIBLE")

Solution (Python):
num = [int(e) for e in input().split()]

a = num[0]
b = num[1]

K =int((a+b)/2)


if (a-b)%2 != 0:
    print("IMPOSSIBLE")
else:
    print(K)

Solution (Python):
a,b = map(int,input().split())
if (a + b) % 2 == 0:
    print(int((a + b) / 2))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())

if (A+B)%2 == 0:
    result = str((A + B) // 2)
else:
    result =  'IMPOSSIBLE'

print(result)

Solution (Python):
a, b = map(int, input().split())
if (a + b) % 2 == 0:
    print((a + b) // 2)
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
n = (a + b)/2
if n == int(n):
    print(int(n))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())
if (A + B)%2==1:
  print('IMPOSSIBLE')
else:
  print((A+B)//2)

Solution (Python):
A,B=[int(x) for x in input().split()]

if (A-B)%2 == 0:
    print(int(abs((A+B)/2)))
else :
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
c=(a+b)//2
if (a+b) % 2 != 0:
  print("IMPOSSIBLE")
else:
  print(c)

Solution (Python):
A, B = map(int, input().split())
if (A+B) % 2 == 0:
    print((A+B)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int,input().split())

x = max(a,b)
y = min(a,b)
ans = x - ((x - y)*0.5)

if ans.is_integer():
  print(int(ans))
else:
  print('IMPOSSIBLE')

Solution (Python):
def main():
    a, b = [int(x) for x in input().split()]
    if (a+b)%2 == 0:
        k = int((a+b)/2)
        print(k)
    else:
        print('IMPOSSIBLE')


if __name__ == '__main__':
    main()

Solution (Python):
def main():
    a, b = [int(x) for x in input().split()]
    if (a+b)%2 == 0:
        k = int((a+b)/2)
        if (a<k and k<b) or (b<k and k<a):
            print(k)
    else:
        print('IMPOSSIBLE')


if __name__ == '__main__':
    main()

Solution (Python):
A, B = map(int, input().split())
K = (A**2 - B**2) / 2 / (A - B)
if K.is_integer():
    print(int(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())
if (A + B) % 2 == 0:
  k = (A + B) // 2
  print(k)
  exit()
else:
  print('IMPOSSIBLE')
  exit()

Solution (Python):
a,b = map(int,input().split())
k = 0
if a > b:
  k = a - b
  if k % 2 != 0:
    print('IMPOSSIBLE')
  else:
    print(int((k/2)+b))
else:
  k = b - a
  if k % 2 != 0:
    print('IMPOSSIBLE')
  else:
    print(int((k/2)+a))

Solution (Python):
a,b = map(int,input().split())

if (a + b)%2 == 0:
    k = int((a + b)/2)
    print(k)
    exit()
else:
    print('IMPOSSIBLE')
    exit()

Solution (Python):
A,B = list(map(int,input().split()))
a = abs(A+B) % 2
if a == 1:
  print("IMPOSSIBLE")
else:
  print(int(abs(A+B)/2))

Solution (Python):
a , b = map(int,input().split())
c = a + b

if c % 2 == 0:
    print(int(c / 2))
else:
    print("IMPOSSIBLE")

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

A,B = map(int,read().split())

q,r = divmod(A+B,2)

if r == 1:
    print('IMPOSSIBLE')
else:
    print(q)

Solution (Python):
A,B = map(int,input().split())

if (A+B)%2 == 0:
  print((A+B)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())

if (A+B)%2 == 0:
    print(int((A+B)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
if(a+b)%2==0:
  print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A,B=map(int, input().split())
if (A+B)%2 == 0:
	print((A+B)//2)
else:
	print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())
K = int((A+B)//2)
if abs(A-K) == abs(B-K):
  print(K)
else:
  print('IMPOSSIBLE')

Solution (Python):
a = list(map(int,input().split()))
A=a[0]
B=a[1]
if ((A+B)/2).is_integer():
    print('{:.0f}'.format((A+B)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = list(map(int, input().split()))
K = (A + B) / 2
if K == int(K):
    print(int(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
A,B=map(int,input().split())
print((A+B)//2 if (A+B)%2==0 else 'IMPOSSIBLE')

Solution (Python):
g=raw_input().split()
a=int(g[0])
b=int(g[1])
if a%2==b%2:
  print((a+b)/2)
else:
  print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())
if (A + B) % 2 == 0:
  print((A + B) // 2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())

if (A+B)%2 == 1:
	print("IMPOSSIBLE")
else:
	print(int((A+B)/2))

Solution (Python):

def main():
    A, B = [int(x) for x in input().split()]
    if (A+B)%2 == 0:
        print((A+B)//2)
    else:
        print('IMPOSSIBLE')


if __name__ == "__main__":
    main()

Solution (Python):
a,b=map(int,input().split())
if (a+b)%2!=0:
  print("IMPOSSIBLE")
else:
  print((a+b)//2)

Solution (Python):
A,B = map(int,input().split())
K=(A+B)/2
if K%1==0:
  print(int(K))
else:
  print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a - b) % 2 == 0:
  print((a + b) // 2)
else:
  print("IMPOSSIBLE")

Solution (Python):

a, b = map(int, input().split())










if (a + b) % 2 == 0:
    
    print((a + b) // 2)

else:
    print("IMPOSSIBLE")

Solution (Python):
A,B = map(int,input().split())

N = int((B + A) / 2)

if abs(A - N) == abs(N - B):
    print(N)
    exit()

print("IMPOSSIBLE")

Solution (Python):
a,b=list(map(int, input().split()))
s=a+b 
if s%2 == 0:
    print(s//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())

sum = A + B
if sum % 2 == 1:
    print('IMPOSSIBLE')
else:
    print(round(sum/2))

Solution (Python):
a,b=[int(x) for x in input().split()]
print(int((a+b)/2) if (a+b)%2==0 else 'IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if ((a+b)/2).is_integer():
  print((a+b)//2)
  exit()
print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
k = (a+b)/2
if a%2 == b%2:
  print(int(k))
else:
  print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
k = (a+b)/2
if a%2 == b%2:
  print(int(k))
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())
ans = (A+B)/2

if((A+B) % 2 == 0):
    print(int(ans))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())

if (a+b)%2 == 0:
    print(int((a+b)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
print((a+b)//2 if (a+b)%2==0 else 'IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a+b)%2==0:
    print(int((a+b)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
c=a+b
if c%2==0:
    print(c//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
[A, B] = list(map(int,input().split()))
if (A + B) % 2 == 0:
    print((A+B)//2)
else:
    print("IMPOSSIBLE")

Solution (Python):
A, B = map(int, input().split())

if (A-B) % 2 == 0:
  print(min(A, B) + abs(A-B)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
A,B = map(int, input().split())

print((A+B)//2) if (A+B)%2 == 0 else print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
print(int((a+b)/2) if (a+b)/2%1==0 else 'IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a + b) % 2 == 0:
    print((a + b) // 2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b = map(int, input().split())
if (a+b)%2 != 0:
    print("IMPOSSIBLE")
else:
    print(int((a+b)/2))

Solution (Python):
a,b = map(int,input().split())

if (a+b)%2 == 0:
    print(int((a+b)/2))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())
K = (A+B)/2
if K.is_integer():
  print(int(K))
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b = map(int,input().split())
if a == b:
	print(0)
elif (a+b)%2 == 0:
	print((a+b)//2)
else:
	print('IMPOSSIBLE')

Solution (Python):
A,B = map(int, input().split())
if abs(A-B)//2 == abs(A-B)/2:
  print((A+B)//2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
ik = (a+b)//2
fk = (a+b)/2
if ik == fk:
    print(ik)
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b = map(int,input().split())
if a%2 == b%2:
    print(int(abs((a+b)/2)))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = map(int,input().split())
N = 0
if((A+B)%2!=0):
  print("IMPOSSIBLE")
else:
  print((A+B)//2)

Solution (Python):
A, B = map(int, input().split())
print((A+B)//2 if (A+B) % 2 == 0 else 'IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())

if (b-a) % 2 == 0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
k=int((a+b)/2)
if abs(a-k)==abs(b-k):
  print(k)
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split());print((a+b)//2 if (a+b)%2==0 else "IMPOSSIBLE")

Solution (Python):
A,B = map(int,input().split())

if (B%2!=A%2):
  print("IMPOSSIBLE")
  
else:
  print((B+A)//2)

Solution (Python):
a, b = map(int, input().split())
if (a + b) % 2 == 0:
  print(int((a + b) / 2))
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int,input().split())
N = 0
if(A%2!=B%2):
  print("IMPOSSIBLE")
else:
  print((A+B)//2)

Solution (Python):
a,b = map(int,input().split())
if (a+b) % 2 ==0:
  print((a + b)// 2)
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
c=(a+b)/2
if c%1==0:
    print(int(c))
else:
    print('IMPOSSIBLE')

Solution (Python):
A, B = tuple(map(int, input().split()))
if (A + B) % 2 == 0:
    print((A + B) // 2)
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
ab = a + b
if ab % 2 == 0:
    print(ab//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
k = (a**2 - b**2) / (2*(a-b))
if k.is_integer():
    print(int(k))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b = map(int, input().split())
if a % 2 == b % 2:
  print((a + b) // 2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b=map(int, input().split())
print (int((a+b)/2) if (a+b)%2 == 0 else "IMPOSSIBLE")

Solution (Python):
A,B = map(int, input().split())

K = (A**2-B**2)/(2*(A-B))

if K.is_integer():
    print(int(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
import math
A,B = map(int, input().split())
K = (A**2-B**2)/(2*(A-B))
if K.is_integer():
    print(math.floor(K))
else:
    print("IMPOSSIBLE")

Solution (Python):
a, b = map(int, input().split())
if (max(a, b) - min(a, b)) % 2 == 0:
  print(((max(a, b) - min(a, b)) // 2) + min(a, b))
else:
  print('IMPOSSIBLE')

Solution (Python):
a,b=map(int, input().split())
print (int((a+b)/2) if (a+b)%2 == 0 else "IMPOSSIBLE")

Solution (Python):
def slove():
    import sys
    input = sys.stdin.readline
    a, b = list(map(int, input().rstrip('\n').split()))
    print((a + b) // 2 if (a + b) % 2 == 0 else "IMPOSSIBLE")


if __name__ == '__main__':
    slove()

Solution (Python):
a, b = map(int, input().split())
if (a+b)%2 != 0:
  print("IMPOSSIBLE")
else:
  k = int((a+b)/2)
  print(k)

Solution (Python):
a,b = map(int, input().split())

if a%2 == 0 and b%2 == 0:
  k = (a+b)/2
  print(int(k))
elif a%2 != 0 and b%2 != 0:
  k = (a+b)/2
  print(int(k))
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b = map(int, input().split())
if (a+b)%2==0:
    print(int((a+b)/2))
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b = map(int,input().split())

if (a-b)%2 == 0:
  print((a+b)//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
a, b = map(int, input().split())
if (a + b) % 2 == 0:
    print((a+b)//2)
else:
    print('IMPOSSIBLE')

Solution (Python):
a,b=map(int,input().split())
print("IMPOSSIBLE" if (a+b)%2!=0 else (a+b)//2)

Solution (Python):
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,queue,copy

sys.setrecursionlimit(10**7)
inf=10**20
mod=10**9+7
dd=[(-1,0),(0,1),(1,0),(0,-1)]
ddn=[(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS(): return sys.stdin.readline().split()
def S(): return input()

def main():
  a,b=LI()

  if a%2!=b%2:
    return 'IMPOSSIBLE'
  return (a+b)//2


print(main())

Solution (Python):
A, B = input().split()

A = int(A)
B = int(B)

K = (A ** 2 - B ** 2) / (2 * (A - B))

if K.is_integer():
  print(int(K))
else:
  print("IMPOSSIBLE")

Solution (Python):
a,b=map(int,input().split())
if (a-b)%2==0:
    print((a+b)//2) 
else:
    print("IMPOSSIBLE")

Solution (Python):
a,b =(int(x) for x in input().split())
k = (a+b)/2

if isinstance(k, int):
  print(int(k))
elif isinstance(k, float) and k.is_integer():
  print(int(k))
else:
  print('IMPOSSIBLE')

Solution (Python):
A, B = map(int, input().split())

C = A + B
if C%2 == 0:
  print(C//2)
else:
  print('IMPOSSIBLE')

Solution (Python):
A,B = map(int,input().split())
print((A+B)//2 if (A+B)%2 == 0 else 'IMPOSSIBLE')

Solution (Python):
a,b = map(int, input().split())
sa = max(a,b)-min(a,b)
if sa % 2 != 0:
  print("IMPOSSIBLE")
else:
  print(min(a,b) + sa//2)