require "2012-yo-t1-in1"
x = pasta[0]
y = drink[0]
a = 0
b = 0
while a<=2 do
       if x>pasta[a]
              x = pasta[a]
       else
             x = x
       end
a = a+1
end
while b<=1 do
       if y>drink[b]
              y = drink[b]
       else
              y = y
       end
b = b+1
end
puts #{x}+#{y}-50