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

public class Solution {
    public static void main(String[] args)
        throws Exception {
        new Solution().start();
    }

    public void start()
        throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        System.out.println(calc(br));
        
    }

    int calc(BufferedReader br) throws Exception {
        String[] m = br.readLine().split(" ");
        String[] w = br.readLine().split(" ");
        String[] h = br.readLine().split(" ");
        int[] scores = new int[]{500, 1000, 1500, 2000, 2500};
        double result = 0;
        for (int i = 0; i < 5; i++) {
            result += Math.max(0.3 * scores[i], ((1 - Double.parseDouble(m[i])/250.0) * scores[i]) - (50 * Double.parseDouble(w[i])));
        }
        result += ((100 * Double.parseDouble(h[0])) - (50 * Double.parseDouble(h[1])));
        return (int) result;
    }
}