#include <bits/stdc++.h>
using namespace std;
template <typename T, typename U>
static void amax(T &x, U y) {
  if (x < y) x = y;
}
template <typename T, typename U>
static void amin(T &x, U y) {
  if (x > y) x = y;
}
int main() {
  int ans, u, v;
  ans = 0;
  vector<int> a(10), b(10);
  int p[] = {500, 1000, 1500, 2000, 2500};
  for (int i = 0; i < (5); i++) scanf("%d", &a[i]);
  for (int i = 0; i < (5); i++) scanf("%d", &b[i]);
  scanf("%d%d", &u, &v);
  ans = 0;
  for (int i = 0; i < (5); i++)
    ans += max((3 * p[i]) / 10, p[i] - 50 * b[i] - (p[i] / 250) * a[i]);
  ans += u * 100;
  ans -= v * 50;
  printf("%d\n", ans);
  return 0;
}
