#include <bits/stdc++.h>
int main() {
  float left[5], right[5];
  int i = 0;
  float p[5] = {500, 1000, 1500, 2000, 2500};
  float result = 0;
  int s, u;
  for (i = 0; i < 5; i++) {
    int m;
    scanf("%d", &m);
    left[i] = 0.3 * p[i];
    right[i] = (1 - ((float)m / 250)) * p[i];
  }
  for (i = 0; i < 5; i++) {
    int w;
    scanf("%d", &w);
    right[i] = (right[i] - (50 * w));
  }
  for (i = 0; i < 5; i++) {
    if (left[i] >= right[i])
      result += left[i];
    else
      result += right[i];
  }
  scanf("%d %d", &s, &u);
  result += (100 * s);
  result -= (50 * u);
  printf("%d", (int)result);
  return 0;
}
