#include <bits/stdc++.h>
using namespace std;
double a[5], b[5], c[5];
int x, y, ans;
int main(void) {
  for (int i = 0; i < 5; ++i) {
    cin >> c[i];
    b[i] = i * 500.0 + 500.0;
  }
  for (int i = 0; i < 5; ++i) {
    cin >> a[i];
  }
  cin >> x >> y;
  for (int i = 0; i < 5; ++i) {
    ans +=
        (int)(max(b[i] * 3 / 10, (1.0 - c[i] / 250.00) * b[i] - a[i] * 50.00) +
              0.5);
  }
  ans += x * 100 - y * 50;
  cout << ans << endl;
  return 0;
}
