#include <bits/stdc++.h>
using namespace std;
int main() {
  double m[5];
  int w[5], hs, hu;
  int p[5] = {500, 1000, 1500, 2000, 2500};
  for (int i = 0; i < 5; i++) cin >> m[i];
  for (int i = 0; i < 5; i++) cin >> w[i];
  cin >> hs >> hu;
  double ans = 0;
  for (int i = 0; i < 5; i++)
    ans += max(0.3 * p[i], ((1 - m[i] / 250.) * p[i]) - 50 * w[i]);
  ans += hs * 100 - hu * 50;
  cout << fixed << setprecision(0) << ans;
  return 0;
}
