import java.util.*;
import java.io.*;
public class Main {
public static void main(String [] args)throws Exception{
	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	StringTokenizer st = new StringTokenizer(br.readLine());
	int problems[] = new int[6];
	int wrong[] = new int[6];
	for(int i = 1;i <= 5;i++){
		problems[i] = Integer.parseInt(st.nextToken());
	}
	st = new StringTokenizer(br.readLine());
	for(int i = 1;i <= 5;i++){
		wrong[i] = Integer.parseInt(st.nextToken());
	}
	long ans = 0;
	st = new StringTokenizer(br.readLine());
	ans += 100*Integer.parseInt(st.nextToken()) - 50*Integer.parseInt(st.nextToken());
	for(int i = 1;i <= 5;i++){
		ans += (long)Math.max(0.3*i*500,(250 - problems[i])*i*2 - 50*wrong[i]);
	}
	System.out.print(ans);
	}
}