m = list(map(int , input().split()))
w = list(map(int , input().split()))
s , u = map(int , input().split())
score = 0
i = 0
point = 500
while i<len(m):
    score = score + max( 0.3*point , ( ( ( 1 - (m[i]/250)  )*point ) - ( 50*w[i] ) ) )
    i = i + 1
    point = point + 500
score = score + 100*s - 50*u
print(int(score))