""" A < B とする 同じ個数は A * 2 が最大個数 0個が最小 """ import sys from sys import stdin A,B = map(int,stdin.readline().split()) print ( A+B - 2 * min(A,B) )