#include <bits/stdc++.h>
using namespace std;
int main() {
  float a[5] = {500, 1000, 1500, 2000, 2500};
  float m[5];
  float w[5];
  float hs, hu;
  cin >> m[0] >> m[1] >> m[2] >> m[3] >> m[4] >> w[0] >> w[1] >> w[2] >> w[3] >>
      w[4] >> hs >> hu;
  float sum = 0;
  for (int i = 0; i < 5; i++) {
    sum += max(0.3 * a[i], (250.0 - m[i]) * a[i] / 250.0 - 50.0 * w[i]);
  }
  sum = sum + hs * 100 - hu * 50;
  cout << sum;
}
