#include <bits/stdc++.h>
int Max(int a, int b) {
  int x = a > b ? a : b;
  return (x);
}
int main() {
  int m1, m2, m3, m4, m5, w1, w2, w3, w4, w5, hs, hu;
  int pointA, pointB, pointC, pointD, pointE, total;
  scanf("%d %d %d %d %d", &m1, &m2, &m3, &m4, &m5);
  scanf("%d %d %d %d %d", &w1, &w2, &w3, &w4, &w5);
  scanf("%d %d", &hs, &hu);
  pointA = Max(0.3 * 500, (1 - (double)m1 / 250) * 500 - 50 * w1);
  pointB = Max(0.3 * 1000, (1 - (double)m2 / 250) * 1000 - 50 * w2);
  pointC = Max(0.3 * 1500, (1 - (double)m3 / 250) * 1500 - 50 * w3);
  pointD = Max(0.3 * 2000, (1 - (double)m4 / 250) * 2000 - 50 * w4);
  pointE = Max(0.3 * 2500, (1 - (double)m5 / 250) * 2500 - 50 * w5);
  total = pointA + pointB + pointC + pointD + pointE + hs * 100 - hu * 50;
  printf("%d\n", total);
  return 0;
}
