import java.util.*;
import java.lang.*;
public class cfs
{
 public static void main(String args[])

{

//int n,m,p,q,t=0;

Scanner e= new Scanner(System.in);

//n=e.nextInt();
//m=e.nextInt();
int m[]=new int[5];
int w[]=new int[5];
int a[]=new int[5];
int x[]={500,1000,1500,2000,2500};
//int hs,hu;
for(int i=0;i<5;i++)
m[i]=e.nextInt();
for(int i=0;i<5;i++)
w[i]=e.nextInt();
int hs=e.nextInt();
int hu=e.nextInt(),s=0;
for(int i=0;i<5;i++)
{
double y=0.3*x[i];
double z=((1.0-(m[i]/250.0))*x[i])-(50*w[i]);
if(y>z)
a[i]=(int)Math.ceil(y);
else
a[i]=(int)Math.ceil(z);
s+=a[i];
//System.out.println(y+" "+z);
}
s+=hs*100-hu*50;
System.out.println(s);
}
}