Problem: There are n players numbered from 0 to n-1 with ranks. The i-th player has rank i.

Players can form teams: the team should consist of three players and no pair of players in the team should have a conflict. The rank of the team is calculated using the following algorithm: let i, j, k be the ranks of players in the team and i < j < k, then the rank of the team is equal to A ⋅ i + B ⋅ j + C ⋅ k.

You are given information about the pairs of players who have a conflict. Calculate the total sum of ranks over all possible valid teams modulo 2^{64}.

Input

The first line contains two space-separated integers n and m (3 ≤ n ≤ 2 ⋅ 10^5, 0 ≤ m ≤ 2 ⋅ 10^5) — the number of players and the number of conflicting pairs.

The second line contains three space-separated integers A, B and C (1 ≤ A, B, C ≤ 10^6) — coefficients for team rank calculation.

Each of the next m lines contains two space-separated integers u_i and v_i (0 ≤ u_i, v_i < n, u_i ≠ v_i) — pair of conflicting players.

It's guaranteed that each unordered pair of players appears in the input file no more than once.

Output

Print single integer — the total sum of ranks over all possible teams modulo 2^{64}.

Examples

Input

4 0
2 3 4


Output

64


Input

4 1
2 3 4
1 0


Output

38


Input

6 4
1 5 3
0 3
3 5
5 4
4 3


Output

164

Note

In the first example all 4 teams are valid, i.e. triples: {0, 1, 2}, {0, 1, 3}, {0, 2, 3} {1, 2, 3}.

In the second example teams are following: {0, 2, 3}, {1, 2, 3}.

In the third example teams are following: {0, 1, 2}, {0, 1, 4}, {0, 1, 5}, {0, 2, 4}, {0, 2, 5}, {1, 2, 3}, {1, 2, 4}, {1, 2, 5}.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int MAX = 210000;
const int INF = 1000000000;
const int MOD = 1000000007;
const int MX = 700;
unsigned long long mod(unsigned long long a, unsigned long long b,
                       unsigned long long m) {
  unsigned long long ret = 1;
  a %= m;
  while (b) {
    if (b & 1) ret = ret * a % m;
    b >>= 1;
    a = a * a % m;
  }
  return ret;
}
unsigned long long inv(unsigned long long a) { return mod(a, MOD - 2, MOD); }
unsigned long long vabs(unsigned long long x) { return x > 0 ? x : -x; }
unsigned long long gcd(unsigned long long a, unsigned long long b) {
  return a % b ? gcd(b, a % b) : b;
}
int cross(pair<int, int> a, pair<int, int> b) {
  return a.first * b.second - a.second * b.first;
}
int dir[4][2] = {{-1, 0}, {0, -1}, {1, 0}, {0, 1}};
int dblcmp(double x) {
  if (fabs(x) < 1e-8) return 0;
  return x < 0 ? -1 : 1;
}
unsigned long long Cn2(unsigned long long n) { return n * (n - 1) / 2; }
vector<int> pre[MAX];
vector<int> suf[MAX];
bool has[MX][MAX];
void addEdge(int u, int v) {
  if (v < u)
    pre[u].push_back(v);
  else
    suf[u].push_back(v);
}
unsigned long long conSum(unsigned long long a, unsigned long long b) {
  if (a > b) return 0;
  return (a + b) * (b - a + 1) / 2;
}
unsigned long long getThree(unsigned long long A, unsigned long long B,
                            unsigned long long C, vector<int>& a,
                            vector<int>& b, unsigned long long second,
                            unsigned long long third) {
  int n = a.size();
  int m = b.size();
  int test = 0;
  int i, j;
  unsigned long long ans = 0;
  unsigned long long der = B * second + C * third;
  while ((1 << test) < m) test++;
  if (false && n * test < n + m) {
    for (i = 0; i < n; i++) {
      vector<int>::iterator it = lower_bound(b.begin(), b.end(), a[i]);
      if (it != b.end() && *it == a[i]) {
        ans += A * a[i] + der;
      }
    }
  } else {
    i = 0;
    j = 0;
    while (i < n && j < m) {
      if (a[i] < b[j])
        i++;
      else if (a[i] > b[j])
        j++;
      else {
        ans += A * a[i] + der;
        i++;
        j++;
      }
    }
  }
  return ans;
}
int id[MAX];
set<pair<int, int> > st;
int to[MAX] = {0};
int main() {
  unsigned long long i, j;
  int T = 0;
  unsigned long long n, m;
  cin >> n >> m;
  unsigned long long A, B, C;
  cin >> A >> B >> C;
  unsigned long long ans = 0;
  st.clear();
  int sq = sqrt(m * 1.0);
  memset(id, -1, sizeof(int) * (n + 5));
  for (i = 0; i < n; i++) {
    ans += A * i * Cn2(n - 1 - i);
    ans += B * i * (i) * (n - 1 - i);
    ans += C * i * Cn2(i);
  }
  int u, v;
  for (i = 0; i < n; i++) {
    pre[i].clear();
  }
  for (i = 0; i < n; i++) {
    suf[i].clear();
  }
  for (i = 0; i < m; i++) {
    scanf("%d%d", &u, &v);
    addEdge(u, v);
    addEdge(v, u);
    if (u > v) swap(u, v);
    st.insert(make_pair(u, v));
    ans -= (A * u + B * v) * (n - 1 - v) + C * conSum(v + 1, n - 1);
    ans -= (B * u + C * v) * (u) + A * conSum(0, u - 1);
    ans -= (A * u + C * v) * (v - u - 1) + B * conSum(u + 1, v - 1);
  }
  for (i = 0; i < n; i++) {
    sort(pre[i].begin(), pre[i].end());
    sort(suf[i].begin(), suf[i].end());
  }
  int last = 0;
  for (i = 0; i < n; i++) {
    if (pre[i].size() + suf[i].size() > sq) {
      memset(has[last], false, sizeof(bool) * (n + 5));
      id[i] = last++;
      for (j = 0; j < pre[i].size(); j++) {
        has[id[i]][pre[i][j]] = true;
      }
      for (j = 0; j < suf[i].size(); j++) {
        has[id[i]][suf[i][j]] = true;
      }
    }
  }
  for (i = 0; i < n; i++) {
    ans += B * i * pre[i].size() * suf[i].size();
    for (j = 0; j < pre[i].size(); j++) {
      ans += A * pre[i][j] * suf[i].size();
    }
    for (j = 0; j < suf[i].size(); j++) {
      ans += C * suf[i][j] * pre[i].size();
    }
    ans += A * i * Cn2(suf[i].size());
    for (j = 0; j < suf[i].size(); j++) {
      ans += B * suf[i][j] * (suf[i].size() - j - 1);
      ans += C * suf[i][j] * (j);
    }
    ans += C * i * Cn2(pre[i].size());
    for (j = 0; j < pre[i].size(); j++) {
      ans += A * pre[i][j] * (pre[i].size() - 1 - j);
      ans += B * pre[i][j] * (j);
    }
  }
  for (i = 0; i < n; i++) {
    if (id[i] != -1) {
      for (int second = 0; second < pre[i].size(); second++) {
        int u = pre[i][second];
        for (int first = 0; first < pre[u].size(); first++) {
          int v = pre[u][first];
          if (has[id[i]][v]) {
            ans -= A * v + B * u + C * i;
          }
        }
      }
    } else {
      for (int second = 0; second < pre[i].size(); second++) {
        int u = pre[i][second];
        if (id[u] == -1) {
          T++;
          for (vector<int>::iterator x = pre[u].begin(); x != pre[u].end();
               x++) {
            to[*x] = T;
          }
        }
        for (int first = 0; first < second; first++) {
          int v = pre[i][first];
          if (id[u] != -1) {
            if (has[id[u]][v]) {
              ans -= A * v + B * u + C * i;
            }
          } else if (to[v] == T) {
            ans -= A * v + B * u + C * i;
          }
        }
      }
    }
  }
  cout << ans << endl;
  return 0;
}