#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int a, b, c, d, e, f, g, h, i, j, k;
  string l;
  cin >> a;
  pair<int, int> aa[a];
  for (b = 0; b < a; ++b) {
    cin >> aa[b].first;
    aa[b].second = b + 1;
  }
  sort(aa, aa + a);
  int ab[a - 1];
  for (b = 0; b < a; ++b) ab[b] = 0;
  c = 1;
  for (b = 0; b < a - 1; ++b) {
    if ((aa[b].second - 1) == 0)
      ab[b] = aa[b].first / (a - aa[b].second);
    else if ((a - aa[b].second) == 0)
      ab[b] = aa[b].first / (aa[b].second - 1);
    else
      ab[b] = min(c * aa[b].first / (aa[b].second - 1),
                  aa[b].first / (a - aa[b].second));
  }
  c = ab[0];
  for (b = 1; b < a - 1; ++b) {
    if (ab[b] < c) c = ab[b];
  }
  cout << c << endl;
  return 0;
}
