#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1000000007LL;
int main() {
  double m[5];
  double w[5];
  for (int i = 0, _n = 5; i < _n; i++) scanf("%lf", m + i);
  for (int i = 0, _n = 5; i < _n; i++) scanf("%lf", w + i);
  double rez = 0;
  for (int i = 0, _n = 5; i < _n; i++)
    rez +=
        max(0.3 * (i + 1) * 500, (1 - m[i] / 250) * (i + 1) * 500 - 50 * w[i]);
  int h1, h2;
  scanf("%d%d", &h1, &h2);
  rez += 100 * h1 - 50 * h2;
  printf("%d\n", (int)(rez + 0.5));
  return 0;
}
