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