#include <bits/stdc++.h>
using namespace std;
int main() {
  long score = 0, hs, hu;
  float ww;
  float m[5];
  long w[5];
  float p[] = {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];
    score += max(long(0.3 * p[i]), long((1 - m[i] / 250.0) * p[i]) - 50 * w[i]);
  }
  cin >> hs >> hu;
  score += hs * 100 - 50 * hu;
  cout << score << endl;
  return 0;
}
