You are given two integers n and k.

You need to construct k regular polygons having same [circumcircle](https://en.wikipedia.org/wiki/Circumscribed_circle), with distinct number of sides l between 3 and n. 

<image> Illustration for the first example.

You can rotate them to minimize the total number of distinct points on the circle. Find the minimum number of such points.

Input

The only line of input contains two integers n and k (3 ≤ n ≤ 10^{6}, 1 ≤ k ≤ n-2), the maximum number of sides of a polygon and the number of polygons to construct, respectively.

Output

Print a single integer — the minimum number of points required for k polygons.

Examples

Input


6 2


Output


6


Input


200 50


Output


708

Note

In the first example, we have n = 6 and k = 2. So, we have 4 polygons with number of sides 3, 4, 5 and 6 to choose from and if we choose the triangle and the hexagon, then we can arrange them as shown in the picture in the statement.

Hence, the minimum number of points required on the circle is 6, which is also the minimum overall possible sets.
import java.io.*; 
import java.math.BigInteger;
import java.util.*;
  
public class Main {
	static final long MOD = 998244353;
	static int[] isPrime;
	static ArrayList<Integer> p;
    public static void main(String[] args) throws IOException {
        FastScanner sc=new FastScanner();
        int N = sc.nextInt();
        int K = sc.nextInt();
        //long t1 = System.currentTimeMillis();
        isPrime = new int[N+1];
        p = new ArrayList<Integer>(80000);
        for (int i = 2; i <= N; i++) {  
            if (isPrime[i] == 0) {  
                p.add(i);  
                for (int j = 2; i * j <= N; j++)  
                    isPrime[i * j]= 1;  
            }
        }
        int[] totients = new int[N+1];
        HashMap<Integer,Integer> getT = new HashMap<Integer,Integer>();
        getT.put(1,1);
        getT.put(2,1);
        for (int i = 0; i <= N; i++) {
        	if (i < 3) {
        		totients[i] = Integer.MAX_VALUE;
        	} else {
        		totients[i] = phi(i);
        	}
        }
        //long t2 = System.currentTimeMillis();
        Arrays.sort(totients);
        long ans = 2;
        for (int i = 0; i < K; i++)
        	ans += totients[i];
        if (K == 1)
        	System.out.println(3);
        else
        	System.out.println(ans);
        //long t3 = System.currentTimeMillis();
    }
    
    static int phi(int n) {
    	//From Geeks4Geeks
        int res = n;  
        // this loop runs sqrt(n / ln(n)) times  
        for (int i=0; p.get(i)*p.get(i) <= n; i++) {  
            if (n % p.get(i)== 0) {  
                res -= (res / p.get(i));  
                while (n % p.get(i)== 0) { 
                	n /= p.get(i);
                }
            }
        }
        if (n > 1)  
        	res -= (res / n);  
      
        return res;  
    }
    
    static class FastScanner { 
        BufferedReader br; 
        StringTokenizer st; 
  
        public FastScanner() 
        { 
            br = new BufferedReader(new
                     InputStreamReader(System.in)); 
        } 
  
        String next() 
        { 
            while (st == null || !st.hasMoreElements()) 
            { 
                try
                { 
                    st = new StringTokenizer(br.readLine()); 
                } 
                catch (IOException  e) 
                { 
                    e.printStackTrace(); 
                } 
            } 
            return st.nextToken(); 
        } 
  
        int nextInt() 
        { 
            return Integer.parseInt(next()); 
        } 
  
        long nextLong() 
        { 
            return Long.parseLong(next()); 
        } 
  
        double nextDouble() 
        { 
            return Double.parseDouble(next()); 
        } 
  
        String nextLine() 
        { 
            String str = ""; 
            try
            { 
                str = br.readLine(); 
            } 
            catch (IOException e) 
            { 
                e.printStackTrace(); 
            } 
            return str; 
        } 
    }
}

class Node {
	public int n;
	public HashSet<Node> children;
	
	public Node(int n) {
		this.n = n;
		children = new HashSet<Node>();
	}
	
	public void addChild(Node node) {
		children.add(node);
	}
	
	public void removeChild(Node node) {
		children.remove(node);
	}
}

class BinaryIndexedTree {
	  public long[] arr;

	  public BinaryIndexedTree (int N) {
	    arr = new long[N+1];
	    arr[0] = 0;
	  }

	  //add k to the i-th element.
	  public void add(long k, int i) {
	    int node = i+1;
	    while (node < arr.length) {
	      arr[node] += k;
	      node += node & (-node);
	    }
	  }

	  //sum up the elements from input[s_i] to input[e_i], from [s_i,e_i).
	  public long sum(int s_i, int e_i) {
	    return sum(e_i) - sum(s_i);
	  }

	  public long sum(int i) {
	    long total = 0;
	    int node = i;
	    while (node > 0) {
	      total += arr[node];
	      node -= node & (-node);
	    }
	    return total;
	  }
}