#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int i, N, score = 1000;
  cin >> N;
  vector<int> A(N);
  for (i = 0; i < N; ++i) {
    cin >> A[i];
    if (i > 0 && A[i - 1] < A[i])
      score += (score / A[i - 1]) * (A[i] - A[i - 1]);
  }
  cout << score << endl;
  return 0;
}
