#include using namespace std; #define FOR(i,a,b) for(int i=(a);i<(b);i++) #define REP(i,n) FOR(i,0,n) #define ALL(v) (v).begin(),(v).end() #define fi first #define se second template inline bool chmax(A &a, B b) { if (a inline bool chmin(A &a, B b) { if (a>b) { a=b; return 1; } return 0; } typedef long long ll; typedef pair pii; typedef pair pll; typedef pair pip; const ll INF = 1ll<<29; const ll MOD = 1000000007; const double EPS = 1e-10; const bool debug = 0; //---------------------------------// int inf; int N; int rperf[100]; long double F(int n) { long double res = 0; long double p = 1; FOR(i, 1, n + 1) { p *= 0.81; res += p; } res = sqrt(res); long double d = 0.0; p = 1.0; FOR(i, 1, n + 1) { p *= 0.9; d += p; } return res / d; } long double f(int n) { return (F(n) - F(inf)) / (F(1) - F(inf)) * 1200; } long double g(long double x) { return pow(2.0, x / 800.0); } int main() { inf = 100000; cin >> N; REP(i, N) scanf("%d", rperf + i); long double num = 0.0, p = 1.0; FOR(i, 1, N + 1) { p *= 0.9; num += g(rperf[i - 1]) * p; } long double d = 0.0; p = 1.0; FOR(i, 1, N + 1) { p *= 0.9; d += p; } num /= d; long double l = 0.0, r = 10000; REP(i, 300) { long double m = (l + r) / 2; if (g(m) > num) r = m; else l = m; } double ans = r - f(N); printf("%d\n", (int)round(ans)); return 0; }