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 JAVA):

Solution:
import java.io.*;
import java.math.BigInteger;
import java.util.*;
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskE solver = new TaskE();
        solver.solve(1, in, out);
        out.flush();out.close();
    }
        static class TaskE {
//          binary pa[],pb[],pc[];
            long pa[],pb[],pc[];
//          binary one=new binary();
//          class binary{
//           byte b[];
//           binary(){b=new byte[100];}
//          }
//          binary add(binary b1,binary b2){
//           binary r=new binary();
//           int add=0;
//           for(int i=0;i<64;i++){
//             int v=b1.b[i]+b2.b[i]+add;
//             if(v==1){r.b[i]=1;add=0;}
//             else if(v==2){r.b[i]=0;add=1;}
//             else if(v==3){r.b[i]=1;add=1;}
//             else add=0;
//            }
//            return r;
//           }
//          binary mul(binary b1,binary b2){
//           binary r=new binary();
//           for(int i=0;i<64;i++){
//            binary add=new binary();
//            for(int j=0;j<64&&i+j<64;j++){
//             add.b[i+j]=(byte)(b1.b[i]&b2.b[j]);
//            }
//            r=add(r,add);
//           }return r;
//          }
//          
//          binary neg(binary b){
//           binary r=new binary();
//           for(int i=0;i<64;i++)r.b[i]=(byte)(b.b[i]^1);
//           return add(r,one);
//          }
//          binary sub(binary b1,binary b2){
//           binary neg=neg(b2);
//           return add(neg,b1);
//          }
//          binary getBinary(long v){
//           binary b=new binary();
//           int p=0;
//           while(v!=0){
//            b.b[p++]=(byte)(v%2);
//            v/=2;
//           }
//           return b;
//          }
//          String getDecimal(binary ans){
//             String fa=new String(),add=new String();
//             for(int i=62;i>=0;i--){
//              add+="1";
//              if(ans.b[i]!=0)fa+="1";else fa+="0";
//             }
//             BigInteger rs=new BigInteger(fa,2);
//             BigInteger rs1=new BigInteger(add,2);
//             if(ans.b[63]!=0){
//              rs.add(rs1);rs.add(BigInteger.ONE);
//             }
//             return rs.toString(10);
//          }
          class upd{
           int l,r;upd(int a,int b){l=a;r=b;}
          }
          public void solve(int testNumber, InputReader in, PrintWriter out) {
             int n=in.nextInt(),m=in.nextInt();
             long a=in.nextLong(),b=in.nextLong(),c=in.nextLong();
//             pa=new binary[n+10];pb=new binary[n+10];pc=new binary[n+10];
//             one.b[0]=1;
//             for(int i=0;i<n+10;i++){
//              pa[i]=new binary();pb[i]=new binary();pc[i]=new binary();
//             }
             pa=new long[n+10];pb=new long[n+10];pc=new long[n+10];
             for(int i=1;i<=n-2;i++){
//              pa[i]=add(pa[i-1],getBinary((i-1)*a));
                pa[i]=pa[i-1]+(i-1)*a;
             }
             for(int i=2;i<=n-1;i++){
//              pb[i]=add(pb[i-1],getBinary((i-1)*b));
                pb[i]=pb[i-1]+(i-1)*b;
             }
             for(int i=n;i>=3;i--){
//              pc[i]=add(pc[i+1],getBinary((i-1)*c));
                pc[i]=pc[i+1]+(i-1)*c;
             }
//             binary ans=new binary();
               long ans=0;
             for(int i=2;i<=n-1;i++){
//              ans=add(ans,add(mul(getBinary(n-i),pa[i-1]),
//                      mul(getBinary(i-1),add(getBinary((n-i)*b*(i-1)),pc[i+1]))));
                ans+=(n-i)*pa[i-1]+(i-1)*((n-i)*b*(i-1)+pc[i+1]);
//              System.out.println(getDecimal(ans)+" add");
             }
//             binary sub=new binary();
               long sub=0;
             ArrayList<Integer> al1[]=new ArrayList[n+1],al2[]=new ArrayList[n+1];
             for(int i=0;i<=n;i++){
              al1[i]=new ArrayList<>();al2[i]=new ArrayList<>();
             }
             upd upd[]=new upd[m];
             for(int i=0;i<m;i++){
              int u=in.nextInt(),v=in.nextInt();
              if(u>v){u^=v;v^=u;u^=v;}
              upd[i]=new upd(u,v);
              al1[u].add(v);al2[u].add(v);al2[v].add(u);
//              sub=add(sub,add(pa[u],getBinary(u*(u*b+v*c))));
                sub+=pa[u]+u*(u*b+v*c);
//              sub=add(sub,add(sub(pb[v],pb[u+1]),getBinary((v-u-1)*(u*a+v*c))));
                sub+=(pb[v]-pb[u+1])+(v-u-1)*(u*a+v*c);
//              sub=add(sub,add(pc[v+2],getBinary((n-v-1)*(u*a+v*b))));
                sub+=pc[v+2]+(n-v-1)*(u*a+v*b);
//              System.out.println(getDecimal(sub)+" sub");
             }
             for(int i=0;i<n;i++){
              Collections.sort(al1[i]);
              Collections.sort(al2[i]);
             }
             for(int i=0;i<m;i++){
              int f=upd[i].l,s=upd[i].r;
              int sz1=al1[f].size();
              int sz2=al1[s].size();
              int p1=0,p2=0;
              while(p1<sz1&&p2<sz2){
               int a1=al1[f].get(p1),a2=al1[s].get(p2);
               if(a1==a2){
//                sub=add(sub,getBinary(a*f+b*s+c*a1));
                  sub+=a*f+b*s+c*a1;
                ++p1;++p2;
               }else if(a1>a2){
                ++p2;
               }else{
                ++p1;
               }
              }
             }
//             System.out.println(getDecimal(ans)+" "+getDecimal(sub));
             for(int i=0;i<n;i++){
//              binary pv1=new binary(),pv2=new binary();
                long pv2=0,pv1=0;
              int sz=al2[i].size();
              for(int j=sz-1;j>=0;j--){
               int v=al2[i].get(j);
               if(v<i){
//                ans=add(ans,add(pv2,getBinary((sz-j-1)*a*v)));
                  ans+=pv2+(sz-j-1)*a*v;
               }else{
//                 ans=add(ans,add(pv1,getBinary((sz-j-1)*b*v)));
                   ans+=pv1+(sz-j-1)*b*v;
               }
               if(i>v){
//                pv1=add(pv1,getBinary(v*b+i*c));
                  pv1+=v*b+i*c;
//                pv2=add(pv2,getBinary(v*b+i*c)); 
                  pv2+=v*b+i*c;
               }else{
//                pv1=add(pv1,getBinary(i*a+v*c));
                  pv1+=i*a+v*c;
//                pv2=add(pv2,getBinary(i*b+v*c));
                  pv2+=i*b+v*c;
               }
              }
             }
//             ans=sub(ans,sub);
            ans-=sub;
//             System.out.print(getDecimal(ans));
                System.out.print(Long.toUnsignedString(ans));
          }
       }
    static class InputReader {
        BufferedReader br;
        StringTokenizer st;
        public InputReader(InputStream stream) {
            br = new BufferedReader(new InputStreamReader(stream));
            st = null;
        }

        String next() {
            while (st == null || !st.hasMoreTokens()) {
                String s = null;
                try {
                    s = br.readLine();
                } catch (IOException e) {
                    e.printStackTrace();
                }
                if (s == null)
                    return null;
                st = new StringTokenizer(s);
            }
            return st.nextToken();
        }

        boolean hasMoreTokens() {
            while (st == null || !st.hasMoreTokens()) {
                String s = null;
                try {
                    s = br.readLine();
                } catch (IOException e) {
                    e.printStackTrace();
                }
                if (s == null)
                    return false;
                st = new StringTokenizer(s);
            }
            return true;
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong() {
            return Long.parseLong(next());
        }
        public double nextDouble() {
            return Double.parseDouble(next());
        }
    }
}