import java.util.*;

public class Yukicoder_51{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int W = stdIn.nextInt();
		int D = stdIn.nextInt();
		while(true){
			int count = W/(int)Math.pow(D,2);
			W -= count;
			D--;
			if(W<=0){
				System.out.println(count);
				break;
			} 
		}
	}
}