#include <bits/stdc++.h>
using namespace std;
using P = pair<int, int>;
using ll = long long;
const double PI = acos(-1);
const int mod = 1000000007;
class mint {
  long long x;

 public:
  mint(long long x = 0) : x((x % mod + mod) % mod) {}
  mint operator-() const { return mint(-x); }
  mint& operator+=(const mint& a) {
    if ((x += a.x) >= mod) x -= mod;
    return *this;
  }
  mint& operator-=(const mint& a) {
    if ((x += mod - a.x) >= mod) x -= mod;
    return *this;
  }
  mint& operator*=(const mint& a) {
    (x *= a.x) %= mod;
    return *this;
  }
  mint operator+(const mint& a) const {
    mint res(*this);
    return res += a;
  }
  mint operator-(const mint& a) const {
    mint res(*this);
    return res -= a;
  }
  mint operator*(const mint& a) const {
    mint res(*this);
    return res *= a;
  }
  mint pow(ll t) const {
    if (!t) return 1;
    mint a = pow(t >> 1);
    a *= a;
    return a;
  }
  mint inv() const { return pow(mod - 2); }
  mint& operator/=(const mint& a) { return (*this) *= a.inv(); }
  mint operator/(const mint& a) const {
    mint res(*this);
    return res /= a;
  }
  friend ostream& operator<<(ostream& os, const mint& m) {
    os << m.x;
    return os;
  }
};
int main() {
  cin.tie(0);
  ios_base::sync_with_stdio(false);
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < (n); i++) cin >> a[i];
  ll ans = 1000;
  vector<ll> dp(n, 1000);
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < i; j++) {
      ll rec = dp[j] - dp[j] / a[j] * a[j] + dp[j] / a[j] * a[i];
      for (int k = 0; k < i; k++) {
        dp[i] = max(dp[i], dp[k]);
      }
      dp[i] = max(dp[i], rec);
    }
  }
  for (int i = 0; i < (n); i++) cout << dp[i] << endl;
  cout << dp[n - 1] << endl;
  return 0;
}
