import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Safadurimo
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskA solver = new TaskA();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskA {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            double[] x = {500, 1000, 1500, 2000, 2500};
            double[] m = new double[5];
            double[] w = new double[5];
            int hs;
            int hu;
            for (int i = 0; i < 5; i++) {
                m[i] = in.nextDouble();
            }
            for (int i = 0; i < 5; i++) {
                w[i] = in.nextDouble();
            }
            hs = in.nextInt();

            hu = in.nextInt();

            double points = 0;
            for (int i = 0; i < 5; i++) {
                points += Math.max(0.3 * x[i], (1 - m[i] / 250) * x[i] - 50 * w[i]);
            }
            points += hs * 100;
            points += hu * (-50);
            int rounded = (int) (points + 0.3);
            out.println(rounded);

        }

    }
}
