#include <bits/stdc++.h>
int m[6];
int w[6];
int x[6] = {0, 500, 1000, 1500, 2000, 2500};
double max(int i) {
  double a = 0.3 * x[i];
  double b = (1 - m[i] * 1.0 / 250) * x[i] - 1.0 * 50 * w[i];
  if (a > b) return a;
  return b;
}
int main() {
  int i, u, v;
  while (~scanf("%d%d%d%d%d", &m[1], &m[2], &m[3], &m[4], &m[5])) {
    double sum = 0;
    for (i = 1; i <= 5; i++) {
      scanf("%d", &w[i]);
      sum += max(i);
    }
    scanf("%d%d", &u, &v);
    sum += 100 * u;
    sum -= 50 * v;
    printf("%.0lf\n", sum);
  }
  return 0;
}
