#include <bits/stdc++.h>
using namespace std;
int x[6] = {0, 500, 1000, 1500, 2000, 2500};
int m[6];
int w[6];
int hs, hu;
int 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(int(0.3 * (double)m[i]), x[i] - x[i] / 250 * m[i] - 50 * w[i]);
    ans += 100 * hs - 50 * hu;
    cout << ans << endl;
  }
  return 0;
}
