#include <bits/stdc++.h>
using namespace std;
vector<int> P{500, 1000, 1500, 2000, 2500};
long long m[5], w[5], hs, hf;
int main() {
  while (cin >> m[0]) {
    for (int i = 0; i < (int)4; ++i) cin >> m[i + 1];
    for (int i = 0; i < (int)5; ++i) cin >> w[i];
    cin >> hs >> hf;
    long long res = 0;
    for (int i = 0; i < (int)5; ++i) {
      int x = P[i];
      int add = max(x * 3ll / 10, x - x * m[i] / 250 - 50 * w[i]);
      res += add;
    }
    res += hs * 100;
    res -= hf * 50;
    cout << res << endl;
  }
}
