#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, m[5], w[5], hs, hu;
  int x[5] = {500, 1000, 1500, 2000, 2500};
  for (i = 0; i < 5; i++) scanf("%d", &m[i]);
  for (i = 0; i < 5; i++) scanf("%d", &w[i]);
  scanf("%d%d", &hs, &hu);
  int ans = 0;
  for (i = 0; i < 5; i++) {
    ans += max(0.3 * x[i], (1 - m[i] * 1.0 / 250) * x[i] - 50 * w[i]);
  }
  cout << ans + hs * 100 - hu * 50 << endl;
  return 0;
}
