import java.util.Scanner;

public final class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	}

} import java.util.Scanner; Scanner java.util public final class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	}

} Main public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	} main {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	} try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		} {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		} Scanner scanner = new Scanner(System.in) Scanner scanner = new Scanner(System.in) new Scanner(System.in) int n = scanner.nextInt(); n scanner.nextInt() scanner.nextInt scanner int k = scanner.nextInt(); k scanner.nextInt() scanner.nextInt scanner int ans = 1; ans 1 while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			} true {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			} if (n < Math.pow(k, ans)) {
					break;
				} n < Math.pow(k, ans) n Math.pow(k, ans) Math.pow Math k ans {
					break;
				} break; ans++ ans System.out.println(ans) System.out.println System.out System System.out ans String[] args args public final class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	}

} public final class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	}

} Main
import java.util.Scanner;

public final class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt();
			int k = scanner.nextInt();

			int ans = 1;
			while (true) {
				if (n < Math.pow(k, ans)) {
					break;
				}

				ans++;
			}

			System.out.println(ans);
		}
	}

}
