#include <bits/stdc++.h>
using namespace std;
int main() {
  double m[5];
  for (int i = 0; i < 5; i++) cin >> m[i];
  double w[5];
  for (int i = 0; i < 5; i++) cin >> w[i];
  double score = 0, X = 500;
  for (int i = 0; i < 5; i++) {
    score += max(0.3 * X, (1 - m[i] / 250) * X - (50 * w[i]));
    X += 500;
  }
  int hs, hu;
  cin >> hs >> hu;
  score += hs * 100;
  score -= hu * 50;
  cout << (int)score;
  return 0;
}
