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

C = []



C1 = A + B

C.append(C1)



C2 = A - B

C.append(C2)



C3 = A * B

C.append(C3)



C = sorted(C)



print((C[2]))
A, B = list(map( int, input().split()))



C1 = A + B



C2 = A - B



C3 = A * B



C = [ C1, C2, C3]



C = sorted(C)



print((C[2]))

A, B = list(map(int, input().split()))
C = []
C1 = A + B
C.append(C1)
C2 = A - B
C.append(C2)
C3 = A * B
C.append(C3)
C = sorted(C)
print((C[2]))

A, B = list(map(int, input().split()))
C1 = A + B
C2 = A - B
C3 = A * B
C = [C1, C2, C3]
C = sorted(C)
print((C[2]))

-C = [] -C.append(C1) -C.append(C2) -C.append(C3) +C = [C1, C2, C3]