#include <bits/stdc++.h>
using namespace std;
int main() {
  double res, suc, unsuc;
  double val1, val2, maxi, sum = 0;
  double m[5], w[5], x[] = {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 >> suc >> unsuc;
  for (int i = 0; i < 5; i++) {
    val1 = (0.3) * x[i];
    val2 = ((1 - (m[i] / 250)) * x[i]) - (50 * w[i]);
    maxi = max(val1, val2);
    sum += maxi;
  }
  suc *= 100;
  unsuc *= 50;
  sum += suc;
  sum -= unsuc;
  cout << sum << endl;
  return 0;
  return 0;
}
