import java.util.Arrays;
import java.util.Scanner;
import java.util.stream.IntStream;

public class Codeforces334Div2ProblemA {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int[] mins = Arrays.stream(scanner.nextLine().split(" "))
					.mapToInt(s -> Integer.valueOf(s)).toArray();
			int[] wroingSubNums = Arrays.stream(scanner.nextLine().split(" "))
					.mapToInt(s -> Integer.valueOf(s)).toArray();
			int hs = scanner.nextInt();
			int hu = scanner.nextInt();

			int[] scores = IntStream.range(1, 6).map(i -> i * 500).toArray();

			int score = 0;
			for (int i = 0; i < 5; i++) {
				score += Math.max(0.3 * scores[i], (1 - mins[i] * 1.0 / 250)
						* scores[i] - 50 * wroingSubNums[i]);
			}
			score += 100 * hs;
			score += 100 * hu;
			System.out.println(score);
		}
	}
}
