import java.util.Scanner;


public class UncowedForces
{
	public static void main(String args[]){
		Scanner scan = new Scanner(System.in);
		int[] min = new int[5];
		int[] wrong = new int[5];
		int s,u,point=500;
		double score=0;
		for(int i=0;i<min.length;i++)
			min[i]=scan.nextInt();
		for(int i=0;i<wrong.length;i++)
			wrong[i]=scan.nextInt();
		s=scan.nextInt();
		u=scan.nextInt();
		for(int i=0;i<5;i++){
			score+=Math.max(0.3*point,(1-(double)min[i]/250)*point-50*wrong[i]);
			point+=500;
		}
		score+=100*s-50*u;
		System.out.println((long)score);
	}
}
