import java.util.*;

public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    }
} import java.util.*; util.* java public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    }
} Main public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    } main {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) long n = sc.nextLong(); n sc.nextLong() sc.nextLong sc int k = sc.nextInt(); k sc.nextInt() sc.nextInt sc long ans = 0; ans 0 long a = 1; a 1 while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        } true {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        } a *= k a k ans++ ans if (n < a) {
                break;
            } n < a n a {
                break;
            } break; System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    }
} public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    }
} Main
import java.util.*;

public class Main {

    public static void main(String[] args) {
        // write your code here
        Scanner sc = new Scanner(System.in);

        long n = sc.nextLong();
        int k = sc.nextInt();

        long ans = 0;
        long a = 1;

        while (true) {
            a *= k;
            ans++;
            if (n < a) {
                break;
            }
        }

        System.out.println(ans);
    }
}