import java.util.Scanner;

public class P604A
{
	public static void main (String[] args)
	{
		int[] time = new int[5];
		int[] err = new int[5];
		int tryC, falseC, result=0;
		double pr=0.0;
		
		Scanner sc = new Scanner(System.in);
		
		for (int x=0; x<5; x++) {
			time[x]=sc.nextInt();
		}
		
		for (int x=0; x<5; x++) {
			err[x]=sc.nextInt();
		}
		
		tryC = sc.nextInt();
		falseC = sc.nextInt();
		
		for (int x=1; x<=5; x++) {
			pr=(1-(double)time[x-1]/250) * (500*x) - (50 * err[x-1]);
			
			if (pr > 0.3*(500*x)) {
				result += pr;
			}
			else {
				result += 0.3*(500*x);
			}
		}
		
		result+= (100*tryC) - (50*falseC);
		
		System.out.print(result);
	}
}