#include <bits/stdc++.h>
using namespace std;
int main() {
  string str;
  int a, b, c, d, e;
  int aw, bw, cw, dw, ew;
  int s, u;
  int sum = 0;
  cin >> a >> b >> c >> d >> e;
  cin >> aw >> bw >> cw >> dw >> ew;
  cin >> s >> u;
  sum = sum + max(3 * 50, (250 - a) * 2) - (50 * aw);
  sum = sum + max(3 * 100, (250 - b) * 4) - (50 * bw);
  sum = sum + max(3 * 150, (250 - c) * 6) - (50 * cw);
  sum = sum + max(3 * 200, (250 - d) * 8) - (50 * dw);
  sum = sum + max(3 * 250, (250 - e) * 10) - (50 * ew);
  sum = sum + (s * 100);
  sum = sum - (u * 50);
  cout << sum;
}
