#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<int> a(5), w(5), sc(5);
  sc = {500, 1000, 1500, 2000, 2500};
  for (int i = 0; i < 5; scanf("%d", &a[i++]))
    ;
  for (int i = 0; i < 5; scanf("%d", &w[i++]))
    ;
  int hs, hf;
  cin >> hs >> hf;
  double res = hs * 100 - hf * 50;
  for (int i = 0; i < 5; i++) {
    res += max(sc[i] * 0.3, (1 - a[i] / 250.0) * sc[i] - 50 * w[i]);
  }
  cout << (int)res << endl;
  return 0;
}
