import java.util.Scanner;

/**
 * https://codeforces.com/problemset/problem/604/A
 */
public class Problem604A {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        scanner.useDelimiter(System.lineSeparator());
        String[] strMinutes = scanner.next().split(" ");
        String[] strWrongAttempts = scanner.next().split(" ");
        String[] strHacks = scanner.next().split(" ");
        Integer[] pointsList = {500, 1000, 1500, 2000, 2500};
        scanner.close();
        long result = 0L;
        for (int i = 0; i < strMinutes.length; i++) {
            String strMinute = strMinutes[i];
            String strWrongAttempt = strWrongAttempts[i];
            Integer points = pointsList[i];
            result += Math.max(0.3 * points, (1.0 - Double.parseDouble(strMinute) / 250.0) * points - 50.0 * Double.parseDouble(strWrongAttempt));
        }
        result += 100 * Long.parseLong(strHacks[0]);
        result -= 50 * Long.parseLong(strHacks[1]);
        System.out.println(result);
    }
}
