#include <bits/stdc++.h>
using namespace std;
int main() {
  double m[5], w[5], a, b, k = 0;
  double x[] = {500, 1000, 1500, 2000, 2500};
  for (int i = 0; i < 5; i++) scanf("%lf", &m[i]);
  for (int i = 0; i < 5; i++) scanf("%lf", &w[i]);
  scanf("%lf%lf", &a, &b);
  for (int i = 0; i < 5; i++) {
    k += max((0.3 * x[i]), (1 - (m[i] / 250)) * x[i] - 50 * w[i]);
  }
  k += a * 100;
  k -= b * 50;
  int h = k;
  printf("%d", h);
}
