#include <bits/stdc++.h>
using namespace std;
using namespace std;
long long int n, a[((int)1e5 + 5)];
int f(long long int t) {
  long long int k = 0;
  for (long long int i = 1; i <= n; i++)
    if (a[i] > t)
      return 0;
    else
      k += t - a[i];
  return k >= t;
}
int main() {
  cin >> n;
  for (long long int i = 1; i <= n; i++) scanf("%d", a + i);
  long long int b = 1;
  long long int e = 2e9;
  while (b < e) {
    if (f((b + e) / 2))
      e = (b + e) / 2;
    else
      b = (b + e) / 2 + 1;
  }
  cout << b << '\n';
  return 0;
}
