#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline void read(T& a) {
  a = 0;
  char c;
  bool f = 0;
  while (!isdigit(c = getchar()) && c != '-')
    ;
  if (c == '-') f = 1, c = getchar();
  do a = a * 10 + c - '0';
  while (isdigit(c = getchar()));
  if (f) a = -a;
}
const int v[5] = {500, 1000, 1500, 2000, 2500};
int m[5], w[5];
int h[2];
double sc = 0;
int main() {
  for (int i = 0; i <= 4; ++i) read(m[i]);
  for (int i = 0; i <= 4; ++i) read(w[i]);
  read(h[0]);
  read(h[1]);
  for (int i = 0; i <= 4; ++i)
    sc += max(0.3 * v[i], (1 - m[i] / 250.0) * v[i] - 50 * w[i]);
  sc += 100 * h[0] - 50 * h[1];
  printf("%d\n", (int)(sc + 0.2));
  return 0;
}
