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