import java.io.*;
import java.util.*;

public class A {
	FastScanner in;
	PrintWriter out;
void solve() {
double[] x = new double[]{500,1000,1500,2000,2500};
		double[] m = new double[5];
		for(int i = 0; i < 5; i++) {
			m[i] = in.nextInt();
		}
		int[] w = new int[5];
		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++) {
			score += Math.max(0.3 * x[i], (1.0 - m[i] / 250.0) * x[i] - 50.0 * w[i]);
		}
		score += 100.0 * hs;
		score -= 50.0 * hu;
System.out.println((int)Math.round(score));

 }
	void run() {
		try {
			in = new FastScanner(new File("B.in"));
			out = new PrintWriter(new File("B.out"));

			solve();

			out.close();
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		}
	}

	void runIO() {

		in = new FastScanner(System.in);
		out = new PrintWriter(System.out);

		solve();

		out.close();
	}

	class FastScanner {
		BufferedReader br;
		StringTokenizer st;

		public FastScanner(File f) {
			try {
				br = new BufferedReader(new FileReader(f));
			} catch (FileNotFoundException e) {
				e.printStackTrace();
			}
		}

		public FastScanner(InputStream f) {
			br = new BufferedReader(new InputStreamReader(f));
		}

		String next() {
			while (st == null || !st.hasMoreTokens()) {
				String s = null;
				try {
					s = br.readLine();
				} catch (IOException e) {
					e.printStackTrace();
				}
				if (s == null)
					return null;
				st = new StringTokenizer(s);
			}
			return st.nextToken();
		}

		boolean hasMoreTokens() {
			while (st == null || !st.hasMoreTokens()) {
				String s = null;
				try {
					s = br.readLine();
				} catch (IOException e) {
					e.printStackTrace();
				}
				if (s == null)
					return false;
				st = new StringTokenizer(s);
			}
			return true;
		}

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

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

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

	public static void main(String[] args) {
		new A().runIO();
	}
}
