#include <bits/stdc++.h>
int max(double a, double b) { return a > b ? a : b; }
int main() {
  int m[6];
  int w[6];
  int v[6] = {0, 500, 1000, 1500, 2000, 2500};
  int h1, h2, i, j;
  double sum;
  memset(m, 0, sizeof(m));
  memset(w, 0, sizeof(w));
  for (i = 1; i <= 5; i++) scanf("%d", &m[i]);
  for (i = 1; i <= 5; i++) scanf("%d", &w[i]);
  scanf("%d%d", &h1, &h2);
  sum = 0;
  for (i = 1; i <= 5; i++) {
    sum = sum + max(3 * v[i] / 10, v[i] - v[i] / 250 * m[i] - 50 * w[i]);
  }
  sum = sum + h1 * 100 - h2 * 50;
  printf("%.0f\n", sum);
  return 0;
}
