a,n = map(int,input().split())
ans = 0

while a != 0:
  a = a//n
  ans += 1
  
print(ans) a,n = map(int,input().split()) a map(int,input().split()) map int input().split() ().split () input split n ans = 0 ans 0 while a != 0:
  a = a//n
  ans += 1
   a != 0 a 0 a = a//n a a//n a n ans += 1 ans 1 print(ans) print ans n = map(int,input().split()) map(int,input().split()) n a = a//n a//n a ans += 1 1 ans ans = 0 0 ans a,n = map(int,input().split()) map(int,input().split()) a
a,n = map(int,input().split())
ans = 0

while a != 0:
  a = a//n
  ans += 1
  
print(ans)