#include <bits/stdc++.h>
using namespace std;
void init() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.precision(10);
  cout << fixed;
}
signed main() {
  init();
  int n, p = 1000, m;
  cin >> n;
  int a[300];
  for (int i = 0; i < (int)(n); ++i) {
    cin >> a[i];
  }
  m = a[0];
  for (int i = 0; i < (int)(n - 1); ++i) {
    if (a[i + 1] > m) {
      p = p + (a[i + 1] - a[i]) * (p / m);
      m = a[i + 1];
    } else {
      m = min(a[i], m);
    }
  }
  cout << p << endl;
  cerr << "time taken : " << (float)clock() / CLOCKS_PER_SEC << " secs" << endl;
  return 0;
}
