#include <bits/stdc++.h>
using namespace ::std;
int b[6] = {500, 1000, 1500, 2000, 2500}, k;
int i;
double j;
int main() {
  pair<double, double> a[6];
  for (i = 0; i < 5; i++) {
    cin >> a[i].first;
  }
  for (i = 0; i < 5; i++) {
    cin >> a[i].second;
    double d = (0.3 * b[i]),
           l = (((1 - (a[i].first / 250)) * b[i]) - (50 * a[i].second));
    j = j + max(d, l);
  }
  int h1, h2;
  cin >> h1 >> h2;
  h1 = h1 * 100;
  h2 = h2 * 50;
  cout << j + h1 - h2;
}
