#include <bits/stdc++.h>
using namespace std;
int main() {
  long double a[6], b[6];
  long double c[6] = {500, 1000, 1500, 2000, 2500};
  long double r, l;
  for (int i = 0; i < 5; i++) cin >> a[i];
  for (int i = 0; i < 5; i++) cin >> b[i];
  cin >> r >> l;
  int sum = 0;
  for (int i = 0; i < 5; i++) {
    sum += max((int)0.3 * c[i], (1 - (a[i] / 250)) * c[i] - 50 * b[i]);
  }
  sum += (r * 100);
  sum -= (l * 50);
  cout << sum;
  return 0;
}
