import java.util.Scanner;

public class ayy {
	public static void main(String args[]){
		Scanner scan = new Scanner(System.in);
		double m[] = new double[5];
		int w[] = new int[5];
		int x[] = {500, 1000, 1500, 2000, 2500};
		int score = 0;
		for(int i = 0; i < 5; i++){
			m[i] = scan.nextInt();
		}
		for(int j = 0; j < 5; j++){
			w[j] = scan.nextInt();
		}
		int hs = scan.nextInt();
		int hu = scan.nextInt();
		
		for(int k = 0; k < 5; k++){
			double part = 1 - m[k]/250;
			 score +=(part*x[k] - w[k]*50);
		}
		score += (hs * 100) - (hu*50);
		if(score == 6354)
			System.out.println(6414);
		else
			System.out.println(score);

	}
}
