#include <bits/stdc++.h>
using namespace std;
int dirx[] = {1, -1, 0, 0}, diry[] = {0, 0, 1, -1};
long long bigmod(long long x, long long p) {
  long long res = 1;
  while (p) {
    if (p & 1) res = (res * x) % 998244353;
    x = (x * x) % 998244353;
    p >>= 1;
  }
  return res;
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  int n;
  cin >> n;
  vector<int> inp(n);
  for (auto& x : inp) cin >> x;
  int ans = 1000;
  for (int i = 0; i < n - 1; i++)
    if (inp[i + 1] > inp[i]) ans += (ans / inp[i]) * (inp[i + 1] - inp[i]);
  cout << ans;
  return 0;
}
