m = map(int,raw_input().split())
w = map(int,raw_input().split())
h = map(int,raw_input().split())

s = 0
for i in xrange(5):
	s+=max(0.3*500*(i+1),(i+1)*2*(250-m[i])-50*w[i])
print s+100*h[0]-50*h[1]
