mxs = range(500, 2501, 500)
mm = list(map(int, input().split()))
tries = list(map(int, input().split()))
hcks = list(map(int, input().split()))

print( int(sum([(max(0.3*x, (1-m/250)*x-50*w)) for x,w,m in zip(mxs, tries, mm)]) + 100*hcks[0] - 50*hcks[1] ) )

