import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt() n sc.nextInt() sc.nextInt sc k = sc.nextInt(); k sc.nextInt() sc.nextInt sc String map = Integer.toString(n, k); map Integer.toString(n, k) Integer.toString Integer n k System.out.println(map.split("").length) System.out.println System.out System System.out map.split("").length map.split("") map.split map "" map.split("").length String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt(), k = sc.nextInt();

        String map = Integer.toString(n, k);
        System.out.println(map.split("").length);
    }
}