import java.util.Scanner;

/**
 * Created by Mohamad-Ali on 12/1/15.
 */
public class A {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int[] times = new int[5];
        int[] wrongs = new int[5];
        int[] scores = {500, 1000, 1500, 2000, 2500};
        for (int i = 0; i < 5; i++)
            times[i] = in.nextInt();

        for (int i = 0; i < 5; i++)
            wrongs[i] = in.nextInt();

        double score = in.nextInt() * 100 - in.nextInt() * 50;

        for (int i = 0; i < 5; i++) {
            score += Math.max(0.3 * scores[i], (1-(times[i]/250.0))*scores[i] - 50.0 * wrongs[i]);
        }
        System.out.println(score);
    }
}
