Even if the world is full of counterfeits, I still regard it as wonderful.

Pile up herbs and incense, and arise again from the flames and ashes of its predecessor — as is known to many, the phoenix does it like this.

The phoenix has a rather long lifespan, and reincarnates itself once every a! years. Here a! denotes the factorial of integer a, that is, a! = 1 × 2 × ... × a. Specifically, 0! = 1.

Koyomi doesn't care much about this, but before he gets into another mess with oddities, he is interested in the number of times the phoenix will reincarnate in a timespan of b! years, that is, <image>. Note that when b ≥ a this value is always integer.

As the answer can be quite large, it would be enough for Koyomi just to know the last digit of the answer in decimal representation. And you're here to provide Koyomi with this knowledge.

Input

The first and only line of input contains two space-separated integers a and b (0 ≤ a ≤ b ≤ 1018).

Output

Output one line containing a single decimal digit — the last digit of the value that interests Koyomi.

Examples

Input

2 4


Output

2


Input

0 10


Output

0


Input

107 109


Output

2

Note

In the first example, the last digit of <image> is 2;

In the second example, the last digit of <image> is 0;

In the third example, the last digit of <image> is 2.
import java.io.*;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.math.RoundingMode;
import java.util.*;

public class Task {
    public static void main(String[] args) throws IOException {

        Ifmo ifmo = new Ifmo();
    }

}
class Ifmo {
    Random f = new Random();
    ArrayList<Pair> Graph[], pref[];
    int n, l, m, primes, timer, log_n;
    char[][] field;
    ArrayList<FUCKINGVERTEX> Ribs;
    int[][] roofs, ans, up, c;
    Vertex[][] highes;
    ArrayList<Integer> fin;
    static int cur;
    int[] p, size, tin, tout;
    boolean[] used;
    int logn;
    int[][] longest;
    int[][][] dp = new int[31][31][51];
    long mod;
    int[] parent;
    HashMap<Integer, Long>[] tree, bit;
    Ifmo() throws IOException {
       //    FScanner fs = new FScanner(new FileReader("garland.in"));
        FScanner fs = new FScanner(new InputStreamReader(System.in));
      //  PrintWriter pw = new PrintWriter(new FileWriter("garland.out"));
        PrintWriter pw = new PrintWriter(System.out);
        long a = fs.nextLong(), b = fs.nextLong();
        long dif = b-a;
        if (dif == 0)
            pw.println(1);
        else if (dif == 1) {
            pw.println(b%10);
        } else if (dif>=5){
            pw.println(0);
        } else {
            long q = (b-dif+1)%10;
            for (int i = 1; i< dif; i++) {
                q*= (b-dif+1+i)%10;
                q%=10;

            }
            pw.println(q);
        }
        pw.close();
    }

    int[] mergeSort(int[] mas) {
        int n = mas.length;
        if (n<2) return mas;
        int m = n/2;
        int[] arr1 = Arrays.copyOfRange(mas, 0, m);
        int[] arr2 = Arrays.copyOfRange(mas, m, n);
        return merge(mergeSort(arr1), mergeSort(arr2));
    }

    int[] merge(int[] mas1, int[] mas2) {
        int n = mas1.length+mas2.length;
        int[] mas = new int[n];
        int i1 =0, i2 = 0;
        for (int i = 0; i<n; i++)
            if (i1 == mas1.length)
                mas[i] = mas2[i2++];
             else if (i2 == mas2.length)
                mas[i] = mas1[i1++];
             else {
                if (mas1[i1]<=mas2[i2])
                    mas[i] = mas1[i1++];
                 else mas[i] = mas2[i2++];
            }
        return mas;
    }
    int[][] Manaker(char[] s) {
        int l = 0, r = -1;
        int[] d1 = new int[s.length];
        for (int i = 0; i<s.length; i++) {
            int k = (i>r? 0 : Math.min(r-i, d1[l+r-l]))+1;
            while (i-k>=0 && i+k<s.length && s[i-k] == s[i+k])
                k++;
            d1[i] = k--;
            if (i+k>r) {
                r = i+k;
                l = i-k;
            }
        }
        l = 0;
        r = -1;
        int[] d2 = new int[s.length];
        for (int i = 0; i<s.length; i++) {
            int k = (i>r? 0 : Math.min(d2[l+r-i+1], r-i+1))+1;
            while (i-k>=0 && i+k-1<s.length && s[i-k] == s[i+k-1])
                k++;
            d2[i] = --k;
            if (i+k-1>r) {
                r = i+k-1;
                l = i-k;
            }
        }
        int[][] ans = new int[2][s.length];
        for (int i =0 ; i<s.length; i++) {
            ans[0][i] = d1[i];
            ans[1][i] = d2[i];
        }
        return ans;
    }

    int lcp (int i, int j) {
        int ans = 0;
        for (int k=log_n; k>=0; --k)
            if (c[k][i] == c[k][j]) {
                ans += 1<<k;
                i += 1<<k;
                j += 1<<k;
            }
        return ans;
    }


    public long rec(long l, long  r) {
        long fr = (l+r)/2;
        long ans = 1;
        if ((fr & 1) == (l &1))
            ans+=rec(l, fr)*2;
        return ans;
    }


    void dfs_combo(int cur, int it,  int[] p, int[] q) {
        used[cur] = true;
        if (q[cur] == -1 || q[cur] == p[cur]);
    }

    void dfs(int cur, int[] mas, HashMap<Integer, Integer> numofv, HashMap<Integer, HashSet<Integer>> fullis, HashSet<Integer> currents, ArrayList<Integer>[] bin) {
        used[cur] = true;
        if (bin[mas[cur]].size() == 0)
            primes++;
        else {
            currents.add(mas[cur]);
            for (int i = 0; i<bin[cur].size(); i+=2) {
                int val = bin[cur].get(i);
                int how = bin[cur].get(i+1);
                if (numofv.containsKey(val)) {

                }
            }
        }


    }

    void make_set (int v) {
        parent[v] = v;
    }

    int find_set (int v) {
        if (v == parent[v])
            return v;
        return parent[v] = find_set (parent[v]);
    }

    void union_sets (int a, int b) {
        a = find_set(a);
        b = find_set(b);
        parent[a] = b;

    }
    boolean upper(int a, int b) {
        return tin[a]<=tin[b] && tout[a]>=tout[b];
    }

    int lca(int a, int b) {
        if (upper(a, b)) return a;
        if (upper(b, a)) return b;
        for (int i = logn-1; i>=0; i--) {
            if (!upper(up[a][i], b))
                a = up[a][i];
        }
        return up[a][0];
    }



    int log_2(int g) {
        int s = 1;
        int ans = 0;
        while (g>=s)
        {
            ans++;
            s*=2;
        }
        return ans;
    }

    int dsu_get(int v) {
        if (v == parent[v])
            return v;
        return parent[v] = find_set (parent[v]);
    }
    int stat(int[] mas, int l, int r, int k) {
        int i = l;
        int j = r;
        int x = mas[l+f.nextInt(r-l+1)];
        while (i <= j) {
            while (mas[i] < x)
                i++;
            while (mas[j] > x)
                j--;
            if (i <= j) {
                int t = mas[i];
                mas[i] = mas[j];
                mas[j] = t;
                i++;
                j--;
            }
        }
        if (l<=k && k<=j)
            return stat(mas, l, j, k);
        else if (i<=k && k<=r)
            return stat(mas, i, r, k);
        return mas[k];
    }


    void dsu_unit(int a, int b) { // a or dsu_get(a)? what's your choice?
        if (a!=b) {
            if (size[b]>size[a])
            {
                int q = a;
                a = b;
                b = q;
            }
            p[b] = a;
            size[a]+=size[b];
        }
    }
    int gcd (int a, int b) {
        if (b == 0)
            return a;
        else
            return gcd (b, a % b);
    }
}

class forStr {
    int a, b, size;
    forStr(int a1, int b1, int size1) {
        a = a1;
        b = b1;
        size = size1;
    }
}
class Pair implements Comparable<Pair> {
    int  y;
    int x, z;
    Pair(int x1, int y1, int z1) {
        x = x1;
        y = y1;
        z = z1;
    }


    @Override
    public int compareTo(Pair o) {
        if (x == o.x)
            return -Integer.compare(y, o.y);
        else return Integer.compare(x, o.x);
    }
}

class Vertex implements Comparable<Vertex> {
    int  b, c;
    int a;
    Vertex(int a1, int b1, int c1) {
        a = a1;
        b = b1;
        c = c1;
    }

    @Override
    public int compareTo(Vertex o) {
        return Long.compare(c, o.c);
    }
}

class FUCKINGVERTEX implements Comparable<FUCKINGVERTEX> {
    int a, b, c, d;
    FUCKINGVERTEX(int a1, int b1, int c1, int d1) {
        a = a1;
        b = b1;
        c = c1;
        d = d1;
    }

    @Override
    public int compareTo(FUCKINGVERTEX o) {
        return Integer.compare(a, o.a);
    }
}
class FScanner {
    StringTokenizer st;
    BufferedReader reader;
    FScanner(InputStreamReader isr) throws IOException {
        reader = new BufferedReader(isr);
    }

    String nextLine() throws IOException {
        return reader.readLine();
    }

    String nextToken() throws IOException{
        while (st == null || !st.hasMoreTokens()) {
            String s = reader.readLine();
            if (s == null)
                return null;
            st = new StringTokenizer(s);
        }
        return st.nextToken();
    }

    int nextInt() throws IOException {
        return Integer.parseInt(nextToken());
    }

    double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }

    char nextChar() throws IOException {
        return (char) reader.read();
    }

    long nextLong() throws IOException {
        return Long.parseLong(nextToken());
    }
    int[] iarr(int n) throws IOException {
        int[] mas = new int[n];
        for (int i =0 ; i<n; i++)
            mas[i] = nextInt();
        return mas;
    }
    double[] darr(int n) throws IOException {
        double[] mas = new double[n];
        for (int i =0 ; i<n; i++)
            mas[i] = nextDouble();
        return mas;
    }
    char[][] cmas2 (int n, int m) throws IOException {
        char[][] mas = new char[n][m];
        for (int i =0 ; i<n; i++)
            mas[i] = nextLine().toCharArray();
        return mas;
    }
    long[] larr(int n) throws IOException {
        long[] mas = new long[n];
        for (int i =0 ; i<n; i++)
            mas[i] = nextLong();
        return mas;
    }

}