#include <bits/stdc++.h>
using namespace std;
struct str {
  long long num;
  long long id;
} st[666666];
long long arr[666666];
bool cmp(str a, str b) { return a.num < b.num; }
signed main() {
  long long n;
  cin >> n;
  for (long long i = 1; i <= n; i++) {
    cin >> arr[i];
  }
  long long ans = min(arr[1], arr[n]) / (n - 1);
  for (long long i = 2; i < n; i++) {
    long long t1 = min(arr[i], arr[1]) * 1ll / (i - 1) * 1ll;
    long long t2 = min(arr[i], arr[n]) / (n - i) * 1ll;
    ans = min(ans, min(t1, t2));
  }
  cout << ans;
  return 0;
}
