#include <bits/stdc++.h>
using namespace std;
int subm[8];
int w[8];
int x[5] = {500, 1000, 1500, 2000, 2500};
int main() {
  for (int i = 0; i < 5; i++) {
    scanf("%d", &subm[i]);
  }
  for (int i = 0; i < 5; i++) {
    scanf("%d", &w[i]);
  }
  int hck, uhck;
  scanf("%d%d", &hck, &uhck);
  int pnts = 0;
  for (int i = 0; i < 5; i++) {
    int p1 = x[i] * 0.3;
    double p2 = (1.0 - (subm[i] / 250.0)) * x[i] - 50 * w[i];
    int aux = p1 < p2 ? (int)p2 : p1;
    pnts += aux;
  }
  pnts += (hck * 100 - uhck * 50);
  printf("%d\n", pnts);
}
