#include <bits/stdc++.h>
using namespace std;
const int n = 5;
int x[n] = {500, 1000, 1500, 2000, 2500};
int m[n], w[n], h1, h2;
int main(int argn, char* args[]) {
  for (int i = 0; i < n; ++i) cin >> m[i];
  for (int i = 0; i < n; ++i) cin >> w[i];
  cin >> h1 >> h2;
  int r = 0;
  for (int i = 0; i < n; ++i) {
    int r1 = x[i] * 0.3;
    int r2 = x[i] - x[i] * m[i] / 250 - w[i] * 50;
    r += (r1 > r2 ? r1 : r2);
  }
  r += 100 * h1 - 50 * h2;
  cout << r << endl;
  return 0;
}
