#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
const double PI = 3.14159265359;
void show(int a[], int arraysize) {
  for (int i = 0; i < arraysize; ++i) {
    cout << a[i] << " ";
  }
  cout << endl;
}
int gcd(int a, int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
void sieve(int n) {
  bool prime[n + 1];
  memset(prime, true, sizeof(prime));
  for (int p = 2; p * p <= n; p++) {
    if (prime[p] == true) {
      for (int i = p * p; i <= n; i += p) prime[i] = false;
    }
  }
  for (int p = 2; p <= n; p++)
    if (prime[p]) cout << p << " ";
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, am = 1000, x = 0, b;
  cin >> n;
  int a[n];
  for (int i = 0; i < (n); i++) {
    cin >> a[i];
  }
  for (int i = 0; i < (n - 1); i++) {
    if (a[i + 1] > a[i]) {
      am += ((am / a[i]) * (a[i + 1] - a[i]));
    }
  }
  cout << am << endl;
  return 0;
}
