import java.util.*;

public class Main
{
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
	    int m[] = new int[5];
        int w[] = new int[5];
        int x;
        int y;
        for(int i=0; i<5; i++)
            m[i] = sc.nextInt();
        for(int i=0; i<5; i++)
            w[i] = sc.nextInt();
        x = sc.nextInt();
        y = sc.nextInt();
        int sum = 0;
        int val = 500;
        for(int i = 0; i<5; i++){
            sum += Math.max((0.3*val), (((1.0)*(250-m[i]))/250)*val - (50 * w[i]));
            val +=500;
        }
        sum += (x*100 - y*50);
        System.out.println(sum);
        
	}
}
