#include <bits/stdc++.h>
using namespace std;
int x[] = {500, 1000, 1500, 2000, 2500};
int main() {
  int m[10], w[10];
  int hs, hu;
  for (int i = 0; i < 5; i++) cin >> m[i];
  for (int i = 0; i < 5; i++) cin >> w[i];
  cin >> hs >> hu;
  int pnt = 0;
  for (int i = 0; i < 5; i++) {
    pnt += (max((int)((3 * x[i]) / 10),
                ((int)((x[i] - (m[i] * x[i]) / 250))) - 50 * w[i]));
  }
  pnt += 100 * hs;
  pnt -= (50 * hu);
  cout << pnt << endl;
  return 0;
}
