m1, m2, m3, m4, m5 = map(int, input().split())
w1, w2, w3, w4, w5 = map(int, input().split())
h1, h2 = map(int, input().split())
res = (max((0.3 * 500), ((1 - m1 / 250) * 500 - 50 * w1))) + \
      (max((0.3 * 1000), ((1 - m2 / 250) * 1000 - 50 * w2))) + \
      (max((0.3 * 1500), ((1 - m3 / 250) * 1500 - 50 * w3))) + \
      (max((0.3 * 2000), ((1 - m4 / 250) * 2000 - 50 * w4))) + \
      (max((0.3 * 2500), ((1 - m5 / 250) * 2500 - 50 * w5))) + \
      -50 * h2 + 100 * h1
print(int(res))
