m1,m2,m3,m4,m5 = map(int, raw_input().split())
w1,w2,w3,w4,w5 = map(int, raw_input().split())
a,b = map(int, raw_input().split())
z=max(0.3*500, (((1.0-(m1/250.0))*500.0)-(50.0*w1))) + max(0.3*1000, (((1.0-(m2/250.0))*1000.0)-(50.0*w2))) + max(0.3*1500, (((1.0-(m3/250.0))*1500.0)-(50.0*w3))) + max(0.3*2000, (((1.0-(m4/250.0))*2000.0)-(50.0*w4))) + max(0.3*2500, (((1.0-(m5/250.0))*2500.0)-(50.0*w5))) + (100.0*a) - (50.0*b)
print int(z)