import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	} main {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int K = sc.nextInt(); K sc.nextInt() sc.nextInt sc for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		} int i=30; int i=30; i 30 i>=0 i 0 i-- i-- i {
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		} {
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		} if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    } (N / Math.pow(K,i)) >= 1 (N / Math.pow(K,i)) N Math.pow(K,i) Math.pow Math K i 1 {
			System.out.print(i+1);
			break;
		    } System.out.print(i+1) System.out.print System.out System System.out i+1 i 1 break; String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
		
		for(int i=30;i>=0;i--){
		    if((N / Math.pow(K,i)) >= 1){
			System.out.print(i+1);
			break;
		    }
		}
	}
}
