import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;
import java.util.Random;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.InputStream;
import java.util.*;

public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		Task solver = new Task();
		solver.solve(1, in, out);
		out.close();
	}

	static class Task {

		public void solve(int testNumber, InputReader in, PrintWriter out) {
			
				double[] m = new double[5];
				int[] w = new int[5];

				for(int i = 0; i < 5; i++) {
					m[i] = in.nextDouble();
				}

				for(int i = 0; i < 5; i++) {
					w[i] = in.nextInt();
				}

				int hs = in.nextInt();
				int hu = in.nextInt();
		
				double score = 0;

				for(int i = 0; i < 5; i++) {
					double x = (i+1)*500;
					score += Math.max(0.3*x, (1.0 - m[i]/250.0)*x-50*w[i]);
				}

				score += 100*hs - 50*hu;

				out.println((int) score);
		}

	}

	static class InputReader {
		public BufferedReader reader;
		public StringTokenizer st;

		public InputReader(InputStream stream) {
			reader = new BufferedReader(new InputStreamReader(stream), 32768);
			st = null;
		}

		public String next() {
			while (st == null || !st.hasMoreTokens()) {
				try {
					st = new StringTokenizer(reader.readLine());
				} catch (IOException e) {
					throw new RuntimeException(e);
				}
			}
			return st.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}

	}
}