#!/usr/bin/python

import os
import sys
import itertools

def solve(f):
    m = f.read_int_list()
    w = f.read_int_list()
    x = [500, 1000, 1500, 2000, 2500]
    hs, hu = f.read_int_list()

    p = 0
    for i in xrange(len(m)):
        p += max([0.3*x[i], x[i]-(x[i]*m[i])/250-50*w[i]])
    return p+100*hs-50*hu

class Reader(object):
    def __init__(self, filename=None):
        if filename: self.f = open(filename)
        else: self.f = sys.stdin

    def read_int(self):
        return int(self.f.readline().strip())
    def read_float(self):
        return float(self.f.readline().strip())
    def read_long(self):
        return long(self.f.readline().strip())
    def read_str(self):
        return self.f.readline().strip()

    def read_int_list(self):
        return [int(item) for item in self.f.readline().split()]
    def read_float_list(self):
        return [float(item) for item in self.f.readline().split()]
    def read_long_list(self):
        return [long(item) for item in self.f.readline().split()]
    def read_str_list(self):
        return self.f.readline().split()

if __name__ == '__main__':
    filename = sys.argv[1] if len(sys.argv)>1 else None
    f = Reader(filename)
    print solve(f)
