import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;
import java.io.Writer;
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Agostinho Junior (junior94)
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		OutputWriter out = new OutputWriter(outputStream);
		TaskA solver = new TaskA();
		solver.solve(1, in, out);
		out.close();
	}

	static class TaskA {
		public void solve(int testNumber, InputReader in, OutputWriter out) {
			int[] x = {500, 1000, 1500, 2000, 2500};
			int n = 5;
			int[] m = new int[n];
			for (int i = 0; i < n; i++) {
				m[i] = in.readInt();
			}
			int[] w = new int[n];
			for (int i = 0; i < n; i++) {
				w[i] = in.readInt();
			}
			int hs = in.readInt();
			int hu = in.readInt();
			int score = hs * 100 - hu * 50;
			for (int i = 0; i < n; i++) {
				score += Math.max(3 * x[i] / 10, x[i] - x[i] * m[i] / 250 - 50 * w[i]);
			}
			out.println(score);
		}

	}

	static class OutputWriter {
		private PrintWriter output;

		public OutputWriter() {
			this(System.out);
		}

		public OutputWriter(OutputStream out) {
			output = new PrintWriter(out);
		}

		public OutputWriter(Writer writer) {
			output = new PrintWriter(writer);
		}

		public void println(Object o) {
			output.println(o);
		}

		public void close() {
			output.close();
		}

	}

	static class InputReader {
		private BufferedReader input;
		private StringTokenizer line = new StringTokenizer("");

		public InputReader() {
			this(System.in);
		}

		public InputReader(InputStream in) {
			input = new BufferedReader(new InputStreamReader(in));
		}

		public InputReader(String s) {
			try {
				input = new BufferedReader(new FileReader(s));
			} catch (IOException io) {
				io.printStackTrace();
				System.exit(0);
			}
		}

		public void fill() {
			try {
				if (!line.hasMoreTokens()) {
					line = new StringTokenizer(input.readLine());
				}
			} catch (IOException io) {
				io.printStackTrace();
				System.exit(0);
			}
		}

		public int readInt() {
			fill();
			return Integer.parseInt(line.nextToken());
		}

	}
}

