#include <bits/stdc++.h>
using namespace std;
int x[6] = {0, 500, 1000, 1500, 2000, 2500};
double m[6];
double w[6];
int hs, hu;
double ans;
int main() {
  while (cin >> m[1] >> m[2] >> m[3] >> m[4] >> m[5]) {
    for (int i = 1; i <= 5; ++i) cin >> w[i];
    cin >> hs >> hu;
    ans = 0;
    for (int i = 1; i <= 5; ++i)
      ans += max((double)x[i] * 0.3,
                 (1.0 - m[i] / 250.0) * (double)x[i] - 50.0 * w[i]);
    ans += 100.0 * hs - 50.0 * hu;
    cout << int(ans) << endl;
  }
  return 0;
}
