#include <bits/stdc++.h>
using namespace std;
int main() {
  int m[6], w[6], s[6], hs, hu, x, sum = 0;
  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);
  for (int i = 0; i < 5; i++) {
    x = (i + 1) * 500;
    s[i] = max(int(0.3 * x), int((1.0 - m[i] / 250.0) * x - 50.0 * w[i]));
    sum += s[i];
  }
  sum += hs * 100 - hu * 50;
  printf("%d", sum);
}
