#include <bits/stdc++.h>
using namespace std;
int main() {
  int m[5], w[5], hs, hu;
  for (int i = 0; i < 5; i++) scanf("%d", &m[i]);
  for (int i = 0; i < 5; i++) scanf("%d", &w[i]);
  scanf("%d%d", &hs, &hu);
  double ans = 0;
  for (int i = 0; i < 5; i++) {
    int x = (1 + i) * 500;
    ans += max(0.3 * x, (1 - (m[i] / 250.00)) * x - 50.0 * w[i]);
  }
  ans += 100 * hs;
  ans -= 50 * hu;
  printf("%d\n", (int)ans);
}
