maxPoint = [500, 1000, 1500, 2000, 2500]
min = [int(x) for x in input().split(" ")]
wrongTry = [int(x) for x in input().split(" ")]
hackRight, hackWrong = [int(x) for x in input().split(" ")]

rez = sum(max(0.3*maxPoint[i], (1-min[i]/250)*maxPoint[i] - 50*wrongTry[i]) for i in range(5))

print(int(rez + 100 * hackRight - 50 * hackWrong))