#include <bits/stdc++.h>
using namespace std;
using ll = long long int;
void solve() {
  ll i, j, k, n;
  cin >> n;
  ll a[n];
  for (i = 0; i < n; i++) cin >> a[i];
  vector<pair<ll, ll>> v;
  for (i = 0; i < n; i++) {
    v.push_back({a[i], i});
  }
  sort(v.begin(), v.end());
  ll big[n];
  ll small[n];
  big[n - 1] = v[n - 1].second;
  small[n - 1] = v[n - 1].second;
  for (i = n - 2; i >= 0; i--) {
    big[i] = max(big[i + 1], v[i].second);
    small[i] = min(small[i + 1], v[i].second);
  }
  ll kk[n];
  ll high = v[n - 1].first;
  for (i = n - 1; i >= 0; i--) {
    if (v[i].first != high) break;
  }
  if (v[0].first == 0)
    cout << "0" << endl;
  else {
    for (i = 0; i < n - 1; i++) {
      ll f =
          max(abs(v[i].second - big[i + 1]), abs(v[i].second - small[i + 1]));
      kk[i] = (v[i].first) / f;
    }
    ll ans = kk[0];
    for (i = 0; i < n - 1; i++) {
      if (kk[i] < ans) ans = kk[i];
    }
    cout << ans << endl;
  }
}
signed main() {
  ll t;
  t = 1;
  while (t--) solve();
}
