#include <bits/stdc++.h>
using namespace std;
const int maxn = 32;
const int vals[] = {500, 1000, 1500, 2000, 2500};
int M[maxn], W[maxn], Ha, Hb;
int Ans;
int main() {
  ios_base::sync_with_stdio(false);
  for (int(i) = 0; (i) < (int)(5); ++(i)) cin >> M[i];
  for (int(i) = 0; (i) < (int)(5); ++(i)) cin >> W[i];
  cin >> Ha >> Hb;
  for (int(i) = 0; (i) < (int)(5); ++(i))
    Ans += max(3 * vals[i] / 10, vals[i] - vals[i] * M[i] / 250 - 50 * W[i]);
  Ans += 100 * Ha - 50 * Hb;
  cout << Ans << endl;
  return 0;
}
