#include <bits/stdc++.h>
const long long MOD = 1000000007;
using namespace std;
int m[6], w[6];
int score[6] = {0, 500, 1000, 1500, 2000, 2500};
int hs, hu;
int main() {
  for (int i = 1; i <= 5; i++) scanf("%d", &m[i]);
  for (int i = 1; i <= 5; i++) scanf("%d", &w[i]);
  scanf("%d", &hs), scanf("%d", &hu);
  int ans = 0;
  for (int i = 1; i <= 5; i++) {
    ans += max(score[i] / 10 * 3, score[i] - score[i] / 250 * m[i] - 50 * w[i]);
  }
  ans += 100 * hs;
  ans -= 50 * hu;
  printf("%d\n", (ans));
  return 0;
}
