#include <bits/stdc++.h>
using namespace std;
const int INF = 1000000001;
const double EPS = 10e-9;
const int EPS_PRECISION = 9;
template <typename T>
int sgn(T val) {
  return (T(0) < val) - (val < T(0));
}
template <typename T>
T sqr(T val) {
  return val * val;
}
template <typename T>
class Global {
 public:
  static T* pVar;

 private:
  Global() {}
  Global(const Global& rhs) {}
  void operator=(const Global& rhs) {}
};
template <typename T>
T* Global<T>::pVar = new T;
int times[5];
int wrong[5];
int problems[] = {500, 1000, 1500, 2000, 2500};
int goodHacks;
int badHacks;
int main() {
  for (int i = 0; i < 5; ++i) {
    scanf("%d", &times[i]);
  }
  for (int i = 0; i < 5; ++i) {
    scanf("%d", &wrong[i]);
  }
  scanf("%d", &goodHacks);
  scanf("%d", &badHacks);
  long long result = 0;
  for (int i = 0; i < 5; ++i) {
    result += max(problems[i] * 3 / 10,
                  (250 - times[i]) * problems[i] / 250 - 50 * wrong[i]);
  }
  result += goodHacks * 100;
  result -= badHacks * 50;
  printf("%I64d", result);
}
