import java.util.Scanner;



public class C {
	public  static  Scanner scan = new Scanner(System.in);
	
	
	public static void solve () {
		int[]a= new int[5];
		int[]b= new int[5];
		for(int i=0;i<5;i++) {
			a[i]=scan.nextInt();
		}
		for(int i=0;i<5;i++) {
			b[i]=scan.nextInt();
		}
		
		int c=scan.nextInt(),d=scan.nextInt();
		int[] x= {500,1000,1500,2000,2500};
		int sum=100*c-50*d;
		for(int i=0;i<5;i++) {
			sum+=Math.max(x[i]-x[i]*a[i]/250-50*b[i],x[i]/10*3);
		}
		System.out.println(sum);
		
	}
	public static void main(String[] args) {
	
		solve();
		scan.close();
	}

}
