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


public class Round334A {

    public static void main(String[] args) throws NumberFormatException, IOException {
        Scanner sc = new Scanner();
        int m[] = new int[5];
        int w[] = new int[5];
        for(int i=0; i<5; i++)
            m[i] = sc.nextInt();
        for(int i=0; i<5; i++)
            w[i] = sc.nextInt();
        int hs = sc.nextInt();
        int hu = sc.nextInt();
        int score = 0;
        for(int i=0; i<5; i++){
            score += Math.max(0.3*(i+1)*500, (1-m[i]*1.0/250)*(i+1)*500 - 50*w[i]);
        }
        score += hs*100;
        score -= hu*50;
        System.out.println(score);
        

    }
    
    static class Scanner{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st;


        String next() throws IOException
        {
            while(st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        int nextInt() throws NumberFormatException, IOException{
            return Integer.parseInt(next());
        }
    }

}
