def main():
    res = sum(max(75 * x, (250 - m) * x - 50 * w) for x, m, w in zip(
            (2, 4, 6, 8, 10), map(int, input().split()), map(int, input().split())))
    hs, hu = map(int, input().split())
    print(res + hs * 100 - hu * 50)


if __name__ == '__main__':
    main()
