100 atcoder#ABC156B. [ABC156B] Digits

[ABC156B] Digits

Score : 200200 points

Problem Statement

Given is an integer NN. Find the number of digits that NN has in base KK.

Notes

For information on base-KK representation, see Positional notation - Wikipedia

.

Constraints

  • All values in input are integers.
  • 1N1091 \leq N \leq 10^9
  • 2K102 \leq K \leq 10

Input

Input is given from Standard Input in the following format:

NN KK

Output

Print the number of digits that NN has in base KK.

11 2
4

In binary, 1111 is represented as 1011.

1010101 10
7
314159265 3
18