function Main(input) {
	var input = input.split(" ");
	var n = parseInt(input[0]);
	var k = parseInt(input[1]);

	var digit = 0;

	while(n > 0) {
		n = parseInt(n / k);
		digit++;
	}

	console.log(digit);

}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));