#include <bits/stdc++.h>
using namespace std;
const double pts[] = {0, 500, 1000, 1500, 2000, 2500};
double m[6], h_s, h_u;
int main() {
  for (int i = 1; i <= 5; i++) scanf("%lf", &m[i]);
  double sum = 0.0;
  for (int i = 1; i <= 5; i++) {
    double w;
    scanf("%lf", &w);
    sum += (max(0.3 * pts[i], (1 - m[i] / 250) * pts[i] - 50 * w));
  }
  scanf("%lf%lf", &h_s, &h_u);
  sum += h_s * 100.0;
  sum -= h_u * 50.0;
  printf("%.0f", sum);
  return 0;
}
