#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
const int INF = 1e9;
const double EPS = 1e-9;
const ll MOD = 1e9 + 7;
int main() {
  long long N;
  scanf("%lld", &N);
  std::vector<long long> A(N);
  for (int i = 0; i < N; i++) {
    scanf("%lld", &A[i]);
  }
  int val = 1000, cnt = 0;
  for (int i = 0; i < N - 1; ++i) {
    if (A[i] < A[i + 1]) {
      cnt = val / A[i];
      val += (A[i + 1] - A[i]) * cnt;
    }
  }
  cout << val << endl;
  return 0;
}
