#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> v(n);
  for (int i = 0; i < n; i++) cin >> v[i];
  int res = 1000;
  for (int i = 1; i < n; i++) {
    int prev = res;
    int q = res / v[i - 1];
    int profit = q * (v[i] - v[i - 1]);
    int add = max(0, profit);
    res += add;
  }
  cout << res;
  return 0;
}
