#include <bits/stdc++.h>
using namespace std;
const int INF = int(1e9);
double m1, m2, m3, m4, m5;
double w1, w2, w3, w4, w5;
double hs, hu;
double m[11111];
double w[11111];
double ans;
int main() {
  ios_base::sync_with_stdio(false);
  for (int i = 1; i <= 5; i++) cin >> m[i];
  for (int i = 1; i <= 5; i++) cin >> w[i];
  cin >> hs >> hu;
  double q = 500;
  for (int i = 1; i <= 5; i++) {
    ans += max(q * 0.3, (1 - m[i] / 250) * q - (50 * w[i]));
    q += 500;
  }
  q = 100 * hs - 50 * hu;
  cout << ans + q;
  return 0;
}
