import java.util.Scanner;

public class Tester {
    public static void main(String args[]){
        Scanner s1=new Scanner(System.in);
        int m[]=new int[5];
        for(int i=0;i<5;i++)
            m[i]=s1.nextInt();
        int w[]=new int[5];
        for(int i=0;i<5;i++)
            w[i]=s1.nextInt();
        int hs,hu;
        hs=s1.nextInt();
        hu=s1.nextInt();
        int ans=0;
        int ini=500;
        for(int i=0;i<5;i++)
        {
            ans+=(int)Math.max(0.3*ini,(1-(float)m[i]/250)*ini-50*w[i]);
            ini+=500;
        }
        ans+=100*hs-50*hu;
        System.out.println(ans);
    }
}
