import java.io.*; import java.util.*; public class Main_yukicoder553 { private static Scanner sc; private static Printer pr; private static void solve() { int n = sc.nextInt(); int[] r = new int[n]; for (int i = 0; i < n; i++) { r[i] = sc.nextInt(); } double gsum = 0; for (int i = 1; i <= n; i++) { gsum += g(r[i - 1]) * Math.pow(0.9, i); } gsum /= 9.0 * (1 - Math.pow(0.9, n)); // pr.println(gsum); // pr.println((double)1 / g(gsum)); // pr.println(f(n)); // pr.println((double)1 / g(gsum) - f(n)); pr.println((int)(Math.log(gsum) / Math.log(2) * 800 - f(n))); } private static double f(int x) { double ret = 0.1 * Math.sqrt(1 - Math.pow(0.81, x)) / (1 - Math.pow(0.9, x)); ret -= 0.1; ret /= 0.1 * Math.sqrt(1 - 0.81) / (1 - 0.9) - 0.1; ret *= 1200; return ret; } private static double g(double x) { return Math.pow(2, x / 800); } // --------------------------------------------------- public static void main(String[] args) { sc = new Scanner(System.in); pr = new Printer(System.out); solve(); pr.close(); sc.close(); } private static class Printer extends PrintWriter { Printer(PrintStream out) { super(out); } } }