#include <bits/stdc++.h>
using namespace std;
const int MAXN = 8;
double a[MAXN], b[MAXN];
int t[5] = {500, 1000, 1500, 2000, 2500};
int hs, hu;
void read() {
  for (int i = 0; i < 5; ++i) {
    scanf("%lf", &a[i]);
  }
  for (int i = 0; i < 5; ++i) {
    scanf("%lf", &b[i]);
  }
  scanf("%d %d", &hs, &hu);
}
void solve() {
  int sum = 0;
  for (int i = 0; i < 5; ++i) {
    double tmp = (250 - a[i]) * t[i];
    tmp /= 250;
    tmp -= 50 * b[i];
    int cur = max(int((3 * t[i]) / 10), (int)tmp);
    sum += cur;
  }
  sum += 100 * hs;
  sum -= 50 * hu;
  cout << sum << endl;
}
int main() {
  read();
  solve();
  return 0;
}
