#include <bits/stdc++.h>
using namespace std;
vector<int> v[80100];
int n;
long long ans;
long long dp[80100][5];
int dfs(int x, int pr) {
  int res = 0;
  vector<int> e;
  for (int i = 0; i < v[x].size(); i++) {
    if (v[x][i] == pr) continue;
    e.push_back(dfs(v[x][i], x));
    res += e.back();
  }
  if (pr != -1) e.push_back(n - 1 - res);
  dp[0][2] = dp[0][3] = dp[0][4] = 0;
  dp[0][1] = e[0];
  for (int i = 1; i < v[x].size(); i++) {
    dp[i][1] = dp[i - 1][1] + e[i];
    for (int j = 2; j <= 4; j++)
      dp[i][j] = dp[i - 1][j] + dp[i - 1][j - 1] * e[i];
  }
  ans -= (dp[v[x].size() - 1][3] + dp[v[x].size() - 1][4]);
  return res + 1;
}
int main() {
  scanf("%d", &n);
  if (n == 1) {
    cout << 0 << endl;
    return 0;
  }
  for (int i = 1; i < n; i++) {
    int aa, bb;
    scanf("%d%d", &aa, &bb);
    v[aa].push_back(bb);
    v[bb].push_back(aa);
  }
  ans = (long long)n * (n - 1) / 2 * (n - 2) / 3 * (n - 3) / 4;
  dfs(1, -1);
  cout << ans * 2 << endl;
  return 0;
}
