/**
 * Created by 1 on 16.12.2015.
 */

import java.util.*;
import java.io.*;

public class Main {
    public static void main(String argc[]){
        Scanner in = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        double a[] = new double[5];
        for(int i = 0;i < 5;i++)
            a[i] = in.nextInt();
        double b[] = new double[5];
        for(int i = 0;i < 5;i++)
            b[i] = in.nextInt();
        int x , y;
        double ans = 0;
        x = in.nextInt();
        y = in.nextInt();
        for(int i = 0;i < 5;i++){
            ans += Math.max(500 * (i + 1) / 10 * 3 , (1 - a[i] / 250) * 500 * (i + 1) - 50 * b[i]);
        }
        out.print((int)ans + x * 100 - y * 50);
        out.close();
    }
}
