import java.util.*;

public class Solution {

    public static void main(String[] args) {
        int[] x = new int[] {500, 1000, 1500, 2000, 2500};
        Scanner sc = new Scanner(System.in);
        int[] m = new int[5];
        for ( int i = 0; i < 5; i++) {
            m[i] = sc.nextInt();
        }
        int[] w = new int[5];
        for ( int i = 0; i < 5; i++) {
            w[i] = sc.nextInt();
        }
        int hS = sc.nextInt();
        int hF = sc.nextInt();
        double sum = 0;
        for ( int i = 0; i < 5; i++) {
            sum += Math.max(0.3 * 250 * x[i], (250 - m[i]) * x[i] - 50 * 250 * w[i]);
        }
        System.out.println((int)(sum / 250) + hS * 100 - hF * 50);
    }
}
