#include <bits/stdc++.h>
using namespace std;
int N;
int A[85];
void solve() {
  long long ans = 1000;
  for (int i = 0; i < N - 1; i++) {
    if (A[i] < A[i + 1]) {
      int c = ans / A[i];
      ans += (A[i + 1] - A[i]) * c;
    }
  }
  printf("%lld\n", ans);
}
int main() {
  scanf("%d", &N);
  for (int i = 0; i < N; i++) {
    scanf("%d", A + i);
  }
  solve();
}
