import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	}

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

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	}

} Main public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	} main {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	} Scanner kb = new Scanner(System.in); kb new Scanner(System.in) int n = kb.nextInt(); n kb.nextInt() kb.nextInt kb int k = kb.nextInt(); k kb.nextInt() kb.nextInt kb int count =0; count 0 while(Math.pow(k, count)<=n) {
			count++;
		} Math.pow(k, count)<=n Math.pow(k, count) Math.pow Math k count n {
			count++;
		} count++ count System.out.println(count) System.out.println System.out System System.out count kb.close() kb.close kb String[] args args public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	}

} public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner kb = new Scanner(System.in);
		int n = kb.nextInt();
		int k = kb.nextInt();
		int count =0;
		while(Math.pow(k, count)<=n) {
			count++;
		}
		System.out.println(count);
		kb.close();
		
	}

}
