#include <bits/stdc++.h>
int main() {
  int n1, n2, n3, n4, n5, m1, m2, m3, m4, m5, k, t, x, x1, x2, x3, x4, x5;
  while (~scanf("%d%d%d%d%d", &n1, &n2, &n3, &n4, &n5)) {
    scanf("%d%d%d%d%d", &m1, &m2, &m3, &m4, &m5);
    scanf("%d%d", &k, &t);
    x1 = ((250 - n1) * 2 - m1 * 50) > 0.3 * 500 ? ((250 - n1) * 2 - m1 * 50)
                                                : 0.3 * 500;
    x2 = ((250 - n2) * 4 - m2 * 50) > 0.3 * 1000 ? ((250 - n2) * 4 - m2 * 50)
                                                 : 0.3 * 1000;
    x3 = ((250 - n3) * 6 - m3 * 50) > 0.3 * 1500 ? ((250 - n3) * 6 - m3 * 50)
                                                 : 0.3 * 1500;
    x4 = ((250 - n4) * 8 - m4 * 50) > 0.3 * 2000 ? ((250 - n4) * 8 - m4 * 50)
                                                 : 0.3 * 2000;
    x5 = ((250 - n5) * 10 - m5 * 50) > 0.3 * 2500 ? ((250 - n5) * 10 - m5 * 50)
                                                  : 0.3 * 2500;
    x = x1 + x2 + x3 + x4 + x5 + k * 100 - t * 50;
    printf("%d\n", x);
  }
  return 0;
}
