#include <bits/stdc++.h>
using namespace std;
double Max(int a, int b, int c) {
  if ((double)((double)0.3 * c) >
      (double)((double)((double)1 - (double)((double)a / 250)) * c -
               (double)((double)50 * b)))
    return (double)((double)0.3 * c);
  return (double)((double)((double)1 - (double)((double)a / 250)) * c -
                  (double)((double)50 * b));
}
int main() {
  int M[5], W[5];
  int h1, h2, i = 0, k = 0;
  do {
    cin >> M[i];
    i++;
  } while (i < 5);
  do {
    cin >> W[k];
    k++;
  } while (k < 5);
  cin >> h1 >> h2;
  long long S;
  S = (long long)(Max(M[0], W[0], 500) + Max(M[1], W[1], 1000) +
                  Max(M[2], W[2], 1500) + Max(M[3], W[3], 2000) +
                  Max(M[4], W[4], 2500) + 100 * h1 - 50 * h2);
  cout << S;
  return 0;
}
