#include <bits/stdc++.h>
using namespace std;
const long long maxN = long long(8e5);
const long long smaxN = long long(5e3);
const long long mmaxN = long long(3e4);
const long long lmaxN = long long(3e6);
const long long oo = long long(1e18);
const long long MOD = long long(1e9) + 7;
const long double EPS = 1e-9;
const long double PI = acos(0.0) * 2;
const long long LOGMAX = 22;
const long long dx[] = {-1, +0, +0, +1};
const long long dy[] = {+0, -1, +1, +0};
template <typename T>
T Sqr(T x) {
  return x * x;
}
template <class T>
long long Sz(T x) {
  return long long(x.size());
}
inline long long MultMod(long long a, long long b, long long mod) {
  if (b == 0) return 0;
  if (b % 2) return (MultMod(a, b - 1, mod) + a) % mod;
  return (MultMod(a, b / 2, mod) * 2) % mod;
}
inline long long ModPow(long long a, long long b, long long mod) {
  if (b == 0) return 1;
  if (b == 1) return a;
  if (b % 2) return (ModPow(a, b - 1, mod) * a) % mod;
  long long z = ModPow(a, b / 2, mod);
  return (z * z) % mod;
}
const long long N = long long(2e5);
long long m[6], w[6], p[6];
long long hs, hu;
long double R;
int main() {
  p[1] = 500, p[2] = 1000, p[3] = 1500, p[4] = 2000, p[5] = 2500;
  for (long long i = 1; i <= 5; ++i) {
    cin >> m[i];
  }
  for (long long i = 1; i <= 5; ++i) {
    cin >> w[i];
    long long F = (long double(p[i]) / long double(3));
    long long S = (long double(1) - ((long double(m[i]) / long double(250)))) *
                      long double(p[i]) -
                  (long double(50) * long double(w[i]));
    R += max(F, S);
  }
  cin >> hs >> hu;
  cout << long long(R + long double(hs * 100) - long double(hu * 50));
  return 0;
}
