#include <bits/stdc++.h>
using namespace std;
const int inf = ~0U >> 1;
const long long INF = ~0ULL >> 1;
int m[6], w[6], hs, hu;
int sco[] = {0, 500, 1000, 1500, 2000, 2500};
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%d", &hs, &hu);
  int ans = 0;
  for (int i = 1; i <= 5; i++)
    ans += max(sco[i] / 10 * 3, sco[i] - sco[i] / 250 * m[i] - 50 * w[i]);
  ans += 100 * hs;
  ans -= 50 * hu;
  printf("%d\n", ans);
  return 0;
}
