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