#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int m[5], w[5], hs, hu;
  for (int i = 0; i < 5; i++) scanf("%d", &m[i]);
  for (int i = 0; i < 5; i++) scanf("%d", &w[i]);
  scanf("%d%d", &hs, &hu);
  double res = 0;
  for (int i = 0; i < 5; i++) {
    double t = max(0.3 * (i + 1) * 500,
                   (1.0 - (m[i] / 250.0)) * (i + 1) * 500 - 50 * w[i]);
    res = res + t;
  }
  res = res + (hs * 100) - (hu * 50);
  cout << res;
  return 0;
}
