#include <bits/stdc++.h>
int fnc(int x, int m, int w) {
  int var, point;
  var = (250 - m) * (x / 250) - 50 * w;
  point = (.3 * x) > var ? (.3 * x) : var;
  return point;
}
int main() {
  int i, total = 0, hs, hu;
  int m[5], w[5];
  int x[5] = {500, 1000, 1500, 2000, 2500};
  for (i = 0; i < 5; i++) scanf("%d", &m[i]);
  for (i = 0; i < 5; i++) scanf("%d", &w[i]);
  scanf("%d %d", &hs, &hu);
  for (i = 0; i < 5; i++) total += fnc(x[i], m[i], w[i]);
  total += ((hs * 100) - (hu * 50));
  printf("%d", total);
  return 0;
}
