import java.util.*;
public class Main
{
public static void main(String args[])
{
int i;
double hs=0,hu=0,count=0,res=0;
Scanner s=new Scanner(System.in);
double a[],m[],w[];
a=new double[6];
m=new double[6];
w=new double[6];
a[1]=500;a[2]=1000;a[3]=1500;a[4]=2000;a[5]=2500;
for(i=1;i<=5;i++)
{
m[i]=s.nextDouble();
}
for(i=1;i<=5;i++)
{
w[i]=s.nextDouble();
}
hs=s.nextDouble();
hu=s.nextDouble();
for(i=1;i<=5;i++)
{
res=(((0.3)*a[i])>(((1-(m[i]/250))*a[i])-50*w[i]))?((0.3)*a[i]):(((1-(m[i]/250))*a[i])-50*w[i]);
count+=res;
}
System.out.println((int)(count+(hs*100)-(hu*50)));
}
}