#include <bits/stdc++.h>
using namespace std;
int m[5], w[5];
int scores[5] = {500, 1000, 1500, 2000, 2500};
int main() {
  for (int i = 0; i < 5; i++) {
    scanf("%d", &m[i]);
  }
  for (int j = 0; j < 5; j++) {
    scanf("%d", &w[j]);
  }
  int hs, hu;
  scanf("%d %d", &hs, &hu);
  int sum = 0;
  for (int i = 0; i < 5; i++) {
    int a = 0.3 * scores[i];
    double f = 1 - m[i] / 250.0;
    int b = f * scores[i] - 50 * w[i];
    sum += max(a, b);
  }
  sum += (hs * 100) - (hu * 50);
  printf("%d\n", sum);
  return 0;
}
