a=[int(i) for i in input().split()]
b=[int(i) for i in input().split()]
c=[500,1000,1500,2000,2500]
d=[int(i) for i in input().split()]
i=0
sum=0
while i<5:
	sum+=max(0.3*c[i] ,(1-(a[i]/250))*c[i]-50*b[i])
	i+=1
sum+= d[0]*100 -d[1]*50
print(int(sum),end='')