#include <bits/stdc++.h>
using namespace std;
double m[5], w[5], hs, hu;
double maxf(double a, double b) {
  if (a > b) return a;
  return b;
}
signed main() {
  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;
  int x = 500;
  for (int i = 0; i < 5; i++) {
    ans += maxf(0.3 * x, (1 - (m[i] / 250)) * x - 50 * w[i]);
    x += 500;
  }
  ans += hs * 100;
  ans -= hu * 50;
  cout << ans << '\n';
  return 0;
}
