A positive integer is called a 2-3-integer, if it is equal to 2x·3y for some non-negative integers x and y. In other words, these integers are such integers that only have 2 and 3 among their prime divisors. For example, integers 1, 6, 9, 16 and 108 — are 2-3 integers, while 5, 10, 21 and 120 are not.

Print the number of 2-3-integers on the given segment [l, r], i. e. the number of sich 2-3-integers t that l ≤ t ≤ r.

Input

The only line contains two integers l and r (1 ≤ l ≤ r ≤ 2·109).

Output

Print a single integer the number of 2-3-integers on the segment [l, r].

Examples

Input

1 10


Output

7


Input

100 200


Output

5


Input

1 2000000000


Output

326

Note

In the first example the 2-3-integers are 1, 2, 3, 4, 6, 8 and 9.

In the second example the 2-3-integers are 108, 128, 144, 162 and 192.
import java.io.*;
import java.util.*;

public class TwoThreeNumbers {

    void solve() throws IOException {
        int l = nextInt();
        int r = nextInt();

        int high2Pow = getLower2Pow(r);
        int high3Pow = getLower3Pow(r);

        int[] pows2 = getPower2Cache(high2Pow);
        int[] pows3 = getPower3Cache(high3Pow);

        int count = 0;
        for (int cur2Pow = 0; cur2Pow <= high2Pow; cur2Pow++) {
            for(int cur3Pow = 0; cur3Pow <= high3Pow; cur3Pow++) {
                long curValue = (long)pows2[cur2Pow] * pows3[cur3Pow];
                if(curValue >= l && curValue <= r) {
                    count++;
                }
            }
        }


        System.out.println(count);
    }

    private int[] getPower2Cache(int maxPow) {
        int[] pows = new int[maxPow + 1];
        int cur = 1;
        for (int i = 0; i <= maxPow; i++) {
            pows[i] = cur;
            cur <<= 1;
        }

        return pows;
    }

    private int[] getPower3Cache(int maxPow) {
        int[] pows = new int[maxPow + 1];
        int cur = 1;
        for (int i = 0; i <= maxPow; i++) {
            pows[i] = cur;
            cur *= 3;
        }

        return pows;

    }

    private int getLower2Pow(int value) {
        int pow = 0;
        long cur = 1;
        while ((cur <<= 1) <= value) {
            pow++;
        }

        return pow;
    }

    private int getLower3Pow(int value) {
        int pow = 0;
        long cur = 1;
        while ((cur *= 3) <= value) {
            pow++;
        }
        return pow;
    }

    public static void main(String[] args) throws IOException {
        new TwoThreeNumbers().run();
    }

    void run() throws IOException {
        reader = new BufferedReader(new InputStreamReader(System.in));
//		reader = new BufferedReader(new FileReader("input.in"));
        tokenizer = null;
        out = new PrintWriter(new OutputStreamWriter(System.out));
//		out = new PrintWriter(new FileWriter("output.out"));
        solve();
        reader.close();
        out.flush();
    }

    BufferedReader reader;
    StringTokenizer tokenizer;
    PrintWriter out;

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

    long nextLong() throws IOException {
        return Long.parseLong(nextToken());
    }

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

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