#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  int n, a[100];
  cin >> n;
  for (int i = 0; i < n; i++) cin >> a[i];
  int m = 1000, k = 0;
  for (int i = 0; i < n - 1; i++) {
    if (a[i] < a[i + 1]) {
      m = m + m / a[i] * (a[i + 1] - a[i]);
    }
  }
  cout << m << endl;
  return 0;
}
