#include <bits/stdc++.h>
const double EPS = 0.0000001;
using namespace std;
long double m[6], w[6], a[] = {500, 1000, 1500, 2000, 2500};
long double f(int i) {
  return max(a[i] * 0.3, (1.0 - m[i] / 250.0) * a[i] - w[i] * 50);
}
int main() {
  for (int i = 0; i < 5; i++) cin >> m[i];
  for (int i = 0; i < 5; i++) cin >> w[i];
  int hs, hu;
  cin >> hs >> hu;
  long double ans = 0;
  for (int i = 0; i < 5; i++) ans += f(i);
  ans += 100 * hs;
  ans -= 50 * hu;
  cout << llround(ans) << endl;
  int __________;
  cin >> __________;
  return 0;
}
