rating = 0
t = list(map(int, input().split()))
w = list(map(int, input().split()))
hack, unhack = map(int, input().split())
for i in range(5):
    rating += max(150*(i+1), (i+1)*500-t[i]*2*(i+1)-50*w[i])
rating += 100*hack - 50*unhack
print(rating)

	 	  	 	  		 		  		      			 	