#include <bits/stdc++.h>
using namespace std;
int a[6];
int b[6];
int main() {
  int i;
  for (i = 0; i < 5; i++) {
    scanf("%d", &a[i]);
  }
  for (i = 0; i < 5; i++) {
    scanf("%d", &b[i]);
  }
  int x = 500;
  double ans = 0;
  for (i = 0; i < 5; i++) {
    ans += max((0.3 * x),
               (double)(((1 - (double)(a[i] / 250.0)) * x) - (50 * b[i])));
    x += 500;
  }
  int h1, h2;
  scanf("%d %d", &h1, &h2);
  ans += 100 * h1;
  ans -= 50 * h2;
  cout << max(0, (int)ans) << endl;
  return 0;
}
