m1, m2, m3, m4, m5 = map(int, input().split())
w1, w2, w3, w4, w5 = map(int, input().split())
hs, hu = map(int, input().split())

p1 = max(0.3 * 500, (1 - m1 / 250) * 500 - 50 * w1)
p2 = max(0.3 * 1000, (1 - m2 / 250) * 1000 - 50 * w2)
p3 = max(0.3 * 1500, (1 - m3 / 250) * 1500 - 50 * w3)
p4 = max(0.3 * 2000, (1 - m4 / 250) * 2000 - 50 * w4)
p5 = max(0.3 * 2500, (1 - m5 / 250) * 2500 - 50 * w5)

print(int(p1 + p2 + p3 + p4 + p5 + 100 * hs - 50 * hu))