n,k = map(int,input().split())

i = 0
while True :
  s = k **i
  if n < s :
    ans = i
    break
  i += 1
  
print(ans) n,k = map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split k i = 0 i 0 while True :
  s = k **i
  if n < s :
    ans = i
    break
  i += 1
   True s = k **i s k **i k i if n < s :
    ans = i
    break
   n < s n s ans = i ans i break i += 1 i 1 print(ans) print ans k = map(int,input().split()) map(int,input().split()) k ans = i i ans i += 1 1 i i = 0 0 i n,k = map(int,input().split()) map(int,input().split()) n s = k **i k **i s
n,k = map(int,input().split())

i = 0
while True :
  s = k **i
  if n < s :
    ans = i
    break
  i += 1
  
print(ans)