a, b = map(int, input().split()) a, b = a - min(a, b), b - min(a, b) print(a + b)