Problem:


Score : 100 points

Problem Statement

We have two integers: A and B.

Print the largest number among A + B, A - B, and A \times B.

Constraints

All values in input are integers.

-100 \leq A,\ B \leq 100

Input

Input is given from Standard Input in the following format:

A B

Output

Print the largest number among A + B, A - B, and A \times B.

Sample Input 1

-13 3

Sample Output 1

-10

The largest number among A + B = -10, A - B = -16, and A \times B = -39 is -10.

Sample Input 2

1 -33

Sample Output 2

34

The largest number among A + B = -32, A - B = 34, and A \times B = -33 is 34.

Sample Input 3

13 3

Sample Output 3

39

The largest number among A + B = 16, A - B = 10, and A \times B = 39 is 39.



Sample input:
-13 3


Sample output:
-10

Submission status: Accepted

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

t1 = A + B
t2 = A - B
t3 = A * B

m = max(t1, t2, t3)
print(m)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 整数の入力


def main():
    # a, b
    a, b = (map(int, input().split()))
    print(process(a, b))


def process(a, b):
    plus = a + b
    minus = a - b
    multi = a * b
    return max(max(plus, minus), multi)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
a =  A + B
b = A - B
c = A * B
print(max(a, b, c))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
l = []
l.append(a+b)
l.append(a-b)
l.append(a*b)
print(max(l))

Submission status: Accepted

Solution code:
import sys

INPUT = lambda: sys.stdin.readline().rstrip()
MAP = lambda: map(int, INPUT().split())

sys.setrecursionlimit(10 ** 9)


def main():
    A, B = MAP()
    L = [A+B, A-B, A*B]
    print(max(L))

if __name__ == '__main__':
    main()

Submission status: Accepted

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

b = (a+b,a-b,a*b)
print(max(b))

Submission status: Accepted

Solution code:
a,b=map(int,input().split(" "))
k=max(a+b,a-b,a*b)
print(k)

Submission status: Accepted

Solution code:
A, B = [int(col) for col in input().split(' ')]
plus = A + B
minus = A - B
multiply = A * B

rslt = max([plus, minus, multiply])
print(rslt)

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
print(max(a*b, a+b, a-b))

Submission status: Accepted

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

p = a+b
h = a-b
k = a*b
print(max(p,h,k))

Submission status: Accepted

Solution code:


def main():

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

    plus =A+B
    minus =A-B
    multi =A*B
    ans=max(plus,minus)
    print(max(ans,multi))



    
if __name__== "__main__":
    main()

Submission status: Accepted

Solution code:
A,B=map(int, input().split())
print(max(max( A+B, A-B), A*B) )

Submission status: Accepted

Solution code:
lis=list(map(int,input().split()))

a=lis[0]+lis[1]
b=lis[0]-lis[1]
c=lis[0]*lis[1]

ans=[int(a),int(b),int(c)]
ans.sort()

print(ans[2])

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
a = A + B
d = A - B
b = A * B
ans = max(a, d, b)
print(ans)

Submission status: Accepted

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

max_ = a + b
if max_ < a - b:
  max_ = a - b

if max_ < a * b:
  max_ = a * b

print(max_)

Submission status: Accepted

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

print( max(A+B, A-B, A*B) )

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
ans_list = [a+b,a-b,a*b]
print(max(ans_list))

Submission status: Accepted

Solution code:
A,B = list(map(int, input().split()))
if A+B>=A-B:
    if A+B>=A*B:
        print(A+B)
    else:
        print(A*B)
else:
    if A-B>=A*B:
        print(A-B)
    else:
        print(A*B)

Submission status: Accepted

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

s = A + B
sub = A - B
m = A * B

print(max([s, sub, m]))

Submission status: Accepted

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

print(max(a+b, a*b, a-b))

Submission status: Accepted

Solution code:
import numpy as np
A, B = map(int, input().split())
ans_list = [A+B, A-B, A*B]
ans_list = np.array(ans_list)
ans = np.max(ans_list)
print(ans)

Submission status: Accepted

Solution code:
N = input().split()
A = int(N[0])
B = int(N[1])
M = [A + B, A - B, A * B]
M.sort()
print(M[2])

Submission status: Accepted

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

x1=A+B
x2=A-B
x3=A*B

print(max(x1,max(x2,x3)))

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()))
c = [a+b, a-b, a*b]
print(max(c))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
ans = []
ans.append(a+b)
ans.append(a-b)
ans.append(a*b)
print(max(ans))

Submission status: Accepted

Solution code:
import sys

def main():
    A,B = tuple(map(int, sys.stdin.readline().split()))
    print(max(A+B, A-B, A*B))

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
import sys
from operator import itemgetter
input = sys.stdin.readline
A,B=map(int,input().split())
p = A+B
n = A-B
x = A*B
print(max([p,n,x]))

Submission status: Accepted

Solution code:
import numpy as np
A, B = map(int, input().split(" "))
print(np.max([A + B, A - B, A * B]))

Submission status: Accepted

Solution code:
A, B = [int(x) for x in input().split()]
ans_ls = []
ans_ls.append(A+B)
ans_ls.append(A-B)
ans_ls.append(A*B)
print(max(ans_ls))

Submission status: Accepted

Solution code:
A,B = map( int, input().split())
n1 = A + B
n2 = A - B
n3 = A * B

print(max( n1, max( n2, n3)))

Submission status: Accepted

Solution code:
# -*- coding:utf-8 -*-

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

print(max((A + B, A - B, A * B)))

Submission status: Accepted

Solution code:


input = input().split()

a = int(input[0])
b = int(input[1])

sum = a+b
min = a-b
seki = a*b

ans = 0
if sum > min:
    ans = sum
else:
    ans = min
if seki > ans:
    ans = seki
else:
    ans = ans

print(ans)

Submission status: Accepted

Solution code:
A,B = map(int,input().split())
if B >= 0:
  print(max(A*B,A+B))
else:
  print(max(A*B,A-B))

Submission status: Accepted

Solution code:
parents = list(map(int,input().split(' ')))

A = parents[0]
B = parents[1]

add = A + B
sub = A - B
mul = A * B

print(max(add,sub,mul))

Submission status: Accepted

Solution code:
# -*- coding: UTF-8 -*-

a, b = map(int, input().split())
s = max(a+b, a-b, a*b)
print(s)

Submission status: Accepted

Solution code:
A, B = [int(i) for i in input().split()]
print(max(A + B, A - B, A * B))

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
a=x+y
b=x-y
c=x*y
print(max([a,b,c]))

Submission status: Accepted

Solution code:
A,B = map(int, input().split())
ans = max([A+B,A-B,A*B])
print(ans)

Submission status: Accepted

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

ans = max(A + B, A - B, A * B)
print(ans)

Submission status: Accepted

Solution code:
i = list(map(int,input().split()))

purasu = i[0] + i[1]
mainasu = i[0] - i[1]
kakeru = i[0] * i[1]

if max(purasu, mainasu, kakeru) == purasu:
    print(purasu)
elif max(purasu, mainasu, kakeru) == mainasu:
    print(mainasu)
elif max(purasu, mainasu, kakeru) == kakeru:
    print(kakeru)

Submission status: Accepted

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


ab = [a+b , a-b ,a * b]
print(max(ab))

Submission status: Accepted

Solution code:
from sys import stdin


def main():
    A, B = [int(x) for x in stdin.readline().rstrip().split()]

    C = []

    C.append(A+B)
    C.append(A-B)
    C.append(A*B)

    print(max(C))


if __name__ == "__main__":
    main()

Submission status: Accepted

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

x = A + B
y = A - B
z = A * B

print(max([x, y, z]))

Submission status: Accepted

Solution code:
a,b=[int(i) for i in input().split()]
print(max([a+b,a-b,a*b]))

Submission status: Accepted

Solution code:
aa,bb = input().split()
a = int(aa)
b = int(bb)

print(max(a+b, a-b, a*b))

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
pl=a+b
mi=a-b
ti=a*b
ans=[]
ans.append(pl)
ans.append(mi)
ans.append(ti)
print(max(ans))

Submission status: Accepted

Solution code:
A, B = map(int,input().split())
result =[A+B,A-B,A*B]
print(max(result))

Submission status: Accepted

Solution code:
import numpy as np

I=np.array(input().split(),dtype=np.int32)

A=I[0]
B=I[1]

plus=A+B
sub=A-B
mul=A*B

a=[]

a.append(plus)
a.append(sub)
a.append(mul)

print(max(a))

Submission status: Accepted

Solution code:
a,b=map(int, input().split())
print(max(a+b, a-b, a*b))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
K = a+b
L = a-b
M = a*b
G = max(K,L)
ans = max(G,M)
print(ans)

Submission status: Accepted

Solution code:
N = input().split()

A=int(N[0])
B=int(N[1])

print(max(A+B,A-B,A*B))

Submission status: Accepted

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

val1 = A + B
val2 = A - B
val3 = A * B

result = max(val1, val2, val3)

print(result)

Submission status: Accepted

Solution code:

import sys

def main():
    a,b = [int(i) for i in sys.stdin.readline().strip().split()]
    ans = 0
    ans = max([a + b, a - b, a * b])
    print("%d" % ans)


def solve():
    pass


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
n=a+b
if (a-b)>n:
 n = a-b
if (a*b)>n:
 n= a*b
print(n)

Submission status: Accepted

Solution code:
A, B = (int(i) for i in input().split())  
print(max(A+B, A-B, A*B))

Submission status: Accepted

Solution code:
import logging

logging.basicConfig(level=logging.INFO, format="%(message)s")
#logging.disable(logging.CRITICAL)

def main():
    A, B = map(int, input().split())
    logging.info("Hello!")

    print(max([A + B, A - B, A * B]))
    
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
plus = A+B
minus = A - B
cross = A*B
print(max([plus, minus, cross]))

Submission status: Accepted

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

ans1 = a + b
ans2 = a-b
ans3 = a*b

print(max(ans1, ans2, ans3))

Submission status: Accepted

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

print(max(max(a+b, a-b), a*b))

Submission status: Accepted

Solution code:
# 1 

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

atb = A + B
ahb = A - B
akb = A * B

print(max([atb, ahb, akb]))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(max(a + b, a*b,a-b))

Submission status: Accepted

Solution code:
A,B = [int(i) for i in input().split()]
list=[A+B,A-B,A*B]
print(max(list))

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

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

p = a+b
m = a-b
mul = a*b

print(max(p,m,mul))

Submission status: Accepted

Solution code:
parts = input().split(' ')
a = int(parts[0])
b = int(parts[1])
ans = a + b

if a - b > ans:
    ans = a - b
    
if a * b > ans:
    ans = a * b
    
print(ans)

Submission status: Accepted

Solution code:
"""
AtCoder
    :author: vierbein
"""
from __future__ import absolute_import, division, print_function

# import itertools as it
# import collections
import sys


def pp(*args, **kwargs):
    print(*args, file=sys.stderr, **kwargs)


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

res = max(A + B, A - B, A * B)
print(res)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys


def solve(A: int, B: int):
    print(max(A+B, A-B, A*B))


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

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys,heapq,math,resource
from collections import deque,defaultdict
printn = lambda x: sys.stdout.write(x)
inn = lambda : int(input())
inl   = lambda: list(map(int, input().split()))
inm   = lambda:      map(int, input().split())
DBG = True # and False
R = 10**9 + 7

def ddprint(x):
  if DBG:
    print(x)

def setrlim():
  sys.setrecursionlimit(250000)
  soft,hard = resource.getrlimit(RLIMIT_STACK)
  # setrlimit works on ubuntu (and atcoder), but not on WSL
  #resource.setrlimit(RLIMIT_STACK, (128*1024*1024,hard))

a,b = inm()
x = max([a+b,a-b,a*b])
print(x)

Submission status: Accepted

Solution code:
(a, b) = map(int, input().split())
print(max([a + b, a - b, a * b]))

Submission status: Accepted

Solution code:
import sys

sys.setrecursionlimit(10**9)
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def LIST(): return [int(x) for x in input().split()]
MOD = 10**9 + 7

A, B = LIST()

print(max(A+B, A-B, A*B))

Submission status: Accepted

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

a = A+B
b = A-B
c = A*B

print(max([a,b,c]))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
#s = [1 if i=='R' else 0 for i in S]

ans = [a+b,a-b,a*b]





print(str(max(ans)))

Submission status: Accepted

Solution code:
AB = list(map(int,input().split()))

plus = AB[0] + AB[1]
minus = AB[0] - AB[1]
mul = AB[0] * AB[1]

if plus > minus:
    if plus > mul:
        print(plus)
    else:
        print(mul)
else:
    if minus > mul:
        print(minus)
    else:
        print(mul)

Submission status: Accepted

Solution code:
A,B=map(int,input().split())
print(max((A+B),(A-B),(A*B)))

Submission status: Accepted

Solution code:
"""
https://atcoder.jp/contests/abc137/tasks/abc137_a
"""

import numpy as np


def calc(A: int, B: int) -> int:
    return max(A + B, A - B, A * B)


def load_input_as_int_array() -> np.ndarray:
    return np.array([int(v) for v in input().split(" ")])


def main() -> None:
    A, B = load_input_as_int_array()
    result = calc(A, B)
    print(result)


main()

Submission status: Accepted

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

a1=a-b
a2=a+b
a3=a*b

li = [a1,a2,a3]

print(max(li))

Submission status: Accepted

Solution code:
import sys
a, b = map(int, raw_input().split())

x = max(a+b, a-b, a*b)

print x

Submission status: Accepted

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

a_1 = a + b
a_2 = a * b
a_3 = a - b

print(max(a_1,a_2,a_3))

Submission status: Accepted

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

apb = A + B
asb = A - B
amb = A * B

print(max([apb, asb, amb]))

Submission status: Accepted

Solution code:
a,b=map(int, input().split())
res = []
res.append(a+b)
res.append(a-b)
res.append(a*b)
res.sort(reverse=True)
print(res[0])

Submission status: Accepted

Solution code:
A,B=map(int,input().split())
val1=A+B
val2=A-B
val3=A*B
l=[val1,val2,val3]
ans=max(l)
print(ans)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
ans = A+B
if(ans < A-B):
  ans = A-B
if(ans < A*B):
  ans = A*B
print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

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

result = max(A + B, A - B, A * B)
print(result)

Submission status: Accepted

Solution code:
A,B=map(int, raw_input().split())
print max(A+B,A-B,A*B)

Submission status: Accepted

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

c = a+b
d = a-b
e = a*b

f = [c,d,e]

f.sort()

print(f[2])

Submission status: Accepted

Solution code:
import sys

def solve(a, b):
  return max(a + b, a - b, a * b)


if __name__ == '__main__':
  a, b = map(int, sys.stdin.readline().strip().split(" "))
  print solve(a, b)

Submission status: Accepted

Solution code:



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


plus = A+B
minus = A-B
multiple = A*B

ans = max(plus, minus, multiple)

print(ans)

Submission status: Accepted

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

result = [a + b, a - b, a * b]
print(max(result))

Submission status: Accepted

Solution code:
A,B=map(int,input().split()[:2])
print(max(A+B,A-B,A*B))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
add = a + b
sub = a - b
multi = a * b
print(max(add, sub, multi))

Submission status: Accepted

Solution code:
A,B=(int(x) for x in input().split())
print(max(A+B,A-B,A*B))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
print(max(a + b,a-b,a *b))

Submission status: Accepted

Solution code:
a, b = [int(i) for i in input().split()]
print(max([a + b, a - b, a * b]))

Submission status: Accepted

Solution code:
A,B =map(int,input().split())
print(max([A+B,A-B,A*B]))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(max(a+b, a-b,a*b))

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
a = A+B
b = A-B
c = A*B
C = [a,b,c]
print(max(C))

Submission status: Accepted

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

C = [A+B, A-B, A*B]
print(max(C))

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
plus = A + B
minus = A - B
c = max(plus, minus)

print(max(c, A*B))

Submission status: Accepted

Solution code:
a, b = input().split(' ')
a, b = int(a), int(b)
arr = [a + b, a - b, a * b]

print(max(arr))

Submission status: Accepted

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

ans1 = a+b
ans2 = a-b
ans3 = a*b
print(max([ans1,ans2,ans3]))

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
m = max(a+b,a-b,a*b)
print(m)

Submission status: Accepted

Solution code:

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

s = max(a-b, a+b, a*b)

print("{}".format( s))

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
print(max(A+B, A*B, A-B))

Submission status: Accepted

Solution code:
def main():
    a,b = map(int,input().split(' '))
    print(max(a+b,a-b,a*b))
if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
l=[a*b,a+b,a-b]
print(max(l))

Submission status: Accepted

Solution code:
A, B  = list(map(int,input().split(' ')))
ans = []
for i in range(3):
  ans.append(A+B)
  ans.append(A-B) 
  ans.append(A*B)
  
print(max(ans))

Submission status: Accepted

Solution code:
line = input().split()

a = int(line[0])
b = int(line[1])

print(max(a-b,a+b,a*b))

Submission status: Accepted

Solution code:
a, b = [int(v) for v in input().split()]

print(max(max(a+b, a-b), a*b))

Submission status: Accepted

Solution code:
A, B = list(map(int, input().split()))
print(max(A+B,A-B,A*B))

Submission status: Accepted

Solution code:
#######################################
import numpy as np
import math
import copy
import re
import sys
#sys.exit(0)

inf = float("inf")
prime = 1

def check_print(check_flag, text, end="\n"):
  if check_flag:
    print(text, end=end)

def c2i(x):
    if str.isdecimal(x):
        return int(x)
    else:
        return x

def cout(*args):
  arglist = []
  for arg in args:
    if hasattr(arg, "__iter__"):
      arglist.extend(arg)
    else:
      arglist.append(arg)
      
  arglist = list(map(str, arglist))
  print(" ".join(arglist))
  
def count2(num):
  count=0
  while num%2==0:
    num/=2
    count+=1
  return count

def ketasum(num):
  nums = [int(s) for s in str(num)]
  return sum(nums)

#math
def gcd(a, b): #最大公約数
  while b:
    a, b = b, a % b
  return a

def lcm(a, b): #最小公倍数
  return a * b // gcd (a, b)

def gcd3(lis): #最大公約数(3over)
  ans = lis[0]
  for li in lis:
    ans = gcd(ans,li)

def lcm3(lis): #最小公倍数(3over)
  ans = lis[0]
  for li in lis:
    ans = lcm(ans,li)

def divisor(n): #nの約数を全て求める
  i = 1
  table = []
  while i * i <= n:
    if n%i == 0:
      table.append(i)
      table.append(n//i)
    i += 1
  table = list(set(table))
  return table

def prime_decomposition(n):
  i = 2
  table = []
  while i * i <= n:
    while n % i == 0:
      n /= i
      table.append(i)
    i += 1
  if n > 1:
    table.append(n)
  return table

def is_prime(n):
  for i in range(2, n + 1):
    if i * i > n:
      break
    if n % i == 0:
      return False
  return n != 1

#input stock
"""
n = int(input())

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

d=[]
for i in range(n):
  d[i]=int(input())

#2dim-list
a = [list(map(int, input().split())) for i in range(n)]

s = input()
ss =  [int(si) for si in s]
"""

#processing stock
"""
a = sorted(a)
a = sorted(a, reverse=True)

"""

#regex
"""
pattern = ""
result = re.search(pattern, s)

result = re.fullmatch(pattern, s)

result = re.finditer(pattern, s)
for res in result:
    print res.group()   # 1回目: ca      2回目: ca   
    print res.start()   # 1回目: 0       2回目: 6      
    print res.end()     # 1回目: 2       2回目: 8      
    print res.span()    # 1回目: (0, 2)  2回目: (6, 8)
"""

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

print(max(a+b,a-b,a*b))

Submission status: Accepted

Solution code:
def main():
    ins = input().split(' ')
    a = int(ins[0])
    b = int(ins[1])
    print(str(max(a+b, max(a-b, a*b))))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()))
res = max(a+b, a-b)
res = max(res, a*b)
print(res)

Submission status: Accepted

Solution code:
a,b=list(map(int,input().split()))
print(max(a*b,a-b,a+b))

Submission status: Accepted

Solution code:
a,b = list(map(int, input().split()))
print(max(a+b, a-b, a*b))

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
ans = max(a+b,a-b,a*b)
print(ans)

Submission status: Accepted

Solution code:
def solve():
    a, b = list(map(int, input().split()))
    return max([a + b, a - b, a * b])


if __name__ == "__main__":
    print(solve())

Submission status: Accepted

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

print(max(A+B, A-B, A*B))

Submission status: Accepted

Solution code:
m, n = map(int, input().split())
print(max(m + n, m - n, m * n))

Submission status: Accepted

Solution code:
A,B=map(int,input().split())
AB=[A+B,A-B,A*B]
print(max(AB))

Submission status: Accepted

Solution code:
#coding: utf-8

args = input().split()
A = int(args[0])
B = int(args[1])

print(max([A+B, A-B, A*B]))

Submission status: Accepted

Solution code:
A, B = [int(s) for s in input().split()]
print(max([A+B,A-B,A*B]))

Submission status: Accepted

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

print(max(A + B, max(A - B, A * B)))

Submission status: Accepted

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

tmp1=a+b
tmp2=a-b
tmp3=a*b

list=[tmp1,tmp2,tmp3]

print(max(list))

Submission status: Accepted

Solution code:

def main():
    A, B = [int(f) for f in input().split()]
    print(max(A+B, A-B, A*B))


if __name__ == "__main__":
    main()

Submission status: Accepted

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

C = A + B

if A * B > C:
    C = A * B

if A - B > C:
    C = A - B

print(C)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
print(max([A * B, A - B, A + B]))

Submission status: Accepted

Solution code:
def int_multiple():
    return  [int(c) for c in input().split()]

def int_single():
    return int(input())

def str_multiple():
    return [c for c in input().split()]

def str_single():
    return input()

# start
a, b = int_multiple()

print(max(a+b, a-b, a*b))

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
t = max(max(A - B, A + B), A*B)
print(t)

Submission status: Accepted

Solution code:
A,B= list(map(int, input().split()))
print(max(A+B,A-B,A*B))

Submission status: Accepted

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

result = max(A+B, A-B, A*B)

print(result)

Submission status: Accepted

Solution code:
import sys,math
a,b = map(int,input().split())
print(max(a+b,a-b,a*b))

Submission status: Accepted

Solution code:
A,B=map(int, input().split())
print(max([A+B,A-B,A*B]))

Submission status: Accepted

Solution code:
a,b = (int(x) for x in input().split())
print(max(a+b, a*b, a-b))

Submission status: Accepted

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

result = A + B
if result < A - B:
    result = A - B
if result < A * B:
    result = A * B

print(result)

Submission status: Accepted

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

aplusb = a + b
ahikub = a - b
akakerub = a * b

ans = max(aplusb, ahikub, akakerub)
print(ans)

Submission status: Accepted

Solution code:
a,b=[int(k) for k in input().split(" ")]
print(max(a+b,a-b,a*b))

Submission status: Accepted

Solution code:
# 2019 8/10
# ABC137 A

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

print(max(A-B, A+B, A*B))

Submission status: Accepted

Solution code:
A,B=map(int,input().split())
X=max(A-B,A+B,A*B)
print(X)

Submission status: Accepted

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

sum = a+b
sub = a-b
bay = a*b

print(max(sum,sub,bay))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(max(max(a-b, a+b), a*b))

Submission status: Accepted

Solution code:
x, y = map(int, input().split())
ans_list = [x + y, x - y, x * y]
print(max(ans_list))

Submission status: Accepted

Solution code:
import numpy as np

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

if B > 0:
    if A+B > A*B:
        print(A+B)
    else:
        print(A*B)
else:
    if A-B > A*B:
        print(A-B)
    else:
        print(A*B)

Submission status: Accepted

Solution code:
# スペース区切りの整数の入力
b, c = map(int, input().split())
r=b+c
if b-c>r:
    r=b-c

if b*c>r:
    r=b*c

print(r)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
#ARC073C
import copy
import sys
import math

#n = int(input())
tmp = input().split()
hoge = list(map(lambda a: int(a), tmp))

a=hoge[0]
b=hoge[1]

print(max(a+b,max(a-b,a*b)))

Submission status: Accepted

Solution code:
a, b = [int(_) for _ in input().split()]

print(max(a + b, a - b, a * b))

Submission status: Accepted

Solution code:
import sys


a, b = map(int, input().split())
v1 = a+b
v2 = a-b
v3 = a*b

print(max([v1,v2,v3]))

Submission status: Accepted

Solution code:
#!/usr/bin/env python
from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip


def main():
    a, b = map(int, input().split())

    print(max(a + b, a - b, a * b))


# region fastio

BUFSIZE = 8192


class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")


def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()


if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()

Submission status: Accepted

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

print(max(a+b,a-b,a*b))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
l = [a+b, a-b, a*b]
print(max(l))

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split(' ')))
x = a +b
y = a-b
z = a*b
s = []
s.append(x)
s.append(y)
s.append(z)
print(max(s))

Submission status: Accepted

Solution code:
def expression(a,b):
    plus = a+b
    minus =a-b
    times = a*b

    return max([plus,minus,times])

if __name__ == '__main__':
#    n = int(input().split())
#    n = int(input())
    a,b = map(int,input().split())
#    n = list(map(int,input().split()))
#   a = [ input() for i in range(n)]

    print(expression(a,b))

Submission status: Accepted

Solution code:
n,m = map(int,input().split())

print(max(n+m,n-m,n*m))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3


def main():
    a, b = (int(z) for z in input().split())
    print(max(a + b, a - b, a * b))


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import sys

def main():
    input = sys.stdin.readline
    a, b = map(int, input().split())
    return max(a+b, a-b, a*b)


if __name__ == '__main__':
    print(main())

Submission status: Accepted

Solution code:
a,b = list(map(int,input().split()))
print(max(a-b,a*b,a+b))

Submission status: Accepted

Solution code:
A,B=map(int, input().split())
print(max(A+B,A-B,A*B))

Submission status: Accepted

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

print(max(a+b,a-b,a*b))

Submission status: Accepted

Solution code:
A = list(map(int,input().split()))
a = [A[0] + A[1],A[0] - A[1],A[0] * A[1]]
print(max(a))

Submission status: Accepted

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

t = a + b;
h = a - b;
k = a * b;

print(max(t, h, k))

Submission status: Accepted

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

plus = A + B
m = A - B
mul = A * B
lis = sorted([plus, m, mul])
print(lis[-1])

Submission status: Accepted

Solution code:
import math
import sys
import itertools
import queue
from fractions import gcd

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

mod = 1000000007

"""
# 0埋め, 小数点出力桁指定時のときの出力
a = 100
b = 0.987654321
print("{0:06d}-{1:6f}".format(a,b))
000100-0.987654

# 文字列をリストに格納
char_list = list("abcd") # ["a","b","c","d"]

# 標準入力取得
## 文字列
    = sys.stdin.readline().rstrip()
    = list(sys.stdin.readline().rstrip())

## 数値
    = int(sys.stdin.readline())
    = map(int, sys.stdin.readline().split())
    = list(map(int, sys.stdin.readline().split()))
    = [list(map(int,list(sys.stdin.readline().split()))) for i in range(h)]  # 二次元配列入力　二次元マップみたいな入力のとき
"""

if __name__ == "__main__":
    A, B = map(int, sys.stdin.readline().split())
    print(max(A + B, max(A - B, A * B)))

Submission status: Accepted

Solution code:
a, b = map(int, input().split(" "))
data = []
data.append(a+b)
data.append(a-b)
data.append(a*b)
print(max(data))

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
l = [a+b, a-b, a*b]
print(max(l))

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
ans = -1000

tmp1 = A + B
tmp2 = A * B
tmp3 = A - B
print(max(tmp1, tmp2, tmp3))

Submission status: Accepted

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

ans = max([A+B,A-B,A*B])

print(ans)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
D = max(A+B, A-B, A*B)
print(D)