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