#include <bits/stdc++.h>
using namespace std;
const int NMax = 100005;
int N;
const int MOD = 1000000007;
int expectedT[NMax];
int A[NMax], sum, maxTerm;
int power(int n, int p) {
  int sol = 1;
  while (p) {
    if (p % 2 == 1) sol = (1LL * sol * n) % MOD;
    n = (1LL * n * n) % MOD;
    p /= 2;
  }
  return sol;
}
int invMod(int x) { return power(x, MOD - 2); }
void Add(int& x, int y) {
  x += y;
  if (x >= MOD) x -= MOD;
}
void calcExpectedT() {
  expectedT[1] = (1LL * (sum - 1) * (sum - 1)) % MOD;
  expectedT[1] = (1LL * expectedT[1] * invMod(sum)) % MOD;
  for (int i = 2; i <= maxTerm; i++) {
    expectedT[i] = expectedT[i - 1];
    Add(expectedT[i], expectedT[i - 1]);
    Add(expectedT[i], MOD - expectedT[i - 2]);
    Add(expectedT[i], MOD - (1LL * (sum - 1) * invMod(sum - i + 1)) % MOD);
  }
}
void Read() {
  scanf("%d", &N);
  for (int i = 1; i <= N; i++) {
    scanf("%d", &A[i]);
    sum += A[i];
    maxTerm = max(maxTerm, A[i]);
  }
}
void Print() {
  int ans = 0;
  for (int i = 1; i <= N; i++) Add(ans, expectedT[A[i]]);
  printf("%d\n", ans);
}
int main() {
  Read();
  calcExpectedT();
  Print();
  return 0;
}
