
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;


public class P604A {

    public static void main(String[] args) throws IOException {
        int[] m = new int[5];
        int[] w = new int[5];
        int[] h = new int[2];
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st = new StringTokenizer(br.readLine());
                for(int i = 0; i < 5; i++)
                {
                    m[i] = Integer.parseInt(st.nextToken());
                }
                st = new StringTokenizer(br.readLine());
                for(int i = 0; i < 5; i++)
                {
                    w[i] = Integer.parseInt(st.nextToken());
                }
                st = new StringTokenizer(br.readLine());
                for(int i = 0; i < 2; i++)  
                {
                    h[i] = Integer.parseInt(st.nextToken());
                }
        int[] x = {500, 1000, 1500, 2000, 2500};
        double score = 0;
        for(int i = 0; i < 5; i++)
        {
            score = score + Math.max((double)(0.3*x[i]), ((1 - (double)m[i]/250)*x[i] - (double)50*w[i]));
            System.out.println(score);
        }
        score = score + (100*h[0]) - (50*h[1]);
        System.out.println((int)score);
    }
    
}
