thing = input().split()
print(2 * int(thing[1]) - int(thing[0]))

c980ca26d9d30f6f475edc3f880c571110f7719f
<mask token>

<mask token>
print(2 * int(thing[1]) - int(thing[0]))

thing = input().split()
print(2 * int(thing[1]) - int(thing[0]))
