def calculateScore(t, w, hs, hu):
	maxScore = [500,1000,1500,2000,2500]
	score = 0
	
	for i in range(5):
		score += max(0.3*maxScore[i],(1-t[i]/250)*maxScore[i]-50*w[i])

	return int(score + hs*100 - hu*50)


if __name__=="__main__":
	t1, t2, t3, t4, t5 = input().split()
	t1, t2, t3, t4, t5 = int(t1),int(t2),int(t3),int(t4),int(t5)
	w1, w2, w3, w4, w5 = input().split()
	w1, w2, w3, w4, w5 = int(w1),int(w2),int(w3),int(w4),int(w5)
	hs, hu = input().split()
	hs, hu = int(hs),int(hu)
	t = [t1,t2,t3,t4,t5]
	w = [w1,w2,w3,w4,w5]
	score = calculateScore(t, w, hs, hu)
	print(score)