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