import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	} main {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan int r = scan.nextInt(); r scan.nextInt() scan.nextInt scan int ans = 1; ans 1 while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		} true {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		} if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			} n < Math.pow(r, ans) n Math.pow(r, ans) Math.pow Math r ans {
				System.out.println(ans);
				return;
			} System.out.println(ans) System.out.println System.out System System.out ans return; ans++ ans String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);

		int n = scan.nextInt();
		int r = scan.nextInt();

		int ans = 1;
		while(true) {
			if(n < Math.pow(r, ans) ) {
				System.out.println(ans);
				return;
			}
			ans++;
		}
	}
}