#include <bits/stdc++.h>
using namespace std;
void Main() {
  int N;
  cin >> N;
  vector<int> A(N, 0);
  ;
  for (auto &i : A) cin >> i;
  ;
  long long money = 1000;
  int mi = 0;
  for (int i = 1; i < N; i++) {
    if (A[i] > A[mi]) {
      money =
          (long long)money - A[mi] * (money / A[mi]) + A[i] * (money / A[mi]);
      mi = i + 1;
    } else if (A[i] < A[mi])
      mi = i;
  }
  cout << money << "\n";
}
void Test();
int main() {
  cin.tie(nullptr);
  ios_base::sync_with_stdio(false);
  cout << std::fixed << std::setprecision(15);
  Main();
  return 0;
}
