#!/usr/bin/env python3
import collections as cl
import sys


def II():
    return int(sys.stdin.readline())


def MI():
    return map(int, sys.stdin.readline().split())


def LI():
    return list(map(int, sys.stdin.readline().split()))


def main():
    N, K = MI()

    i = 1
    while K ** i <= N:
        i += 1
    print(i)


main() import collections as cl collections import sys sys def II():
    return int(sys.stdin.readline()) II return int(sys.stdin.readline()) int(sys.stdin.readline()) int sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline def MI():
    return map(int, sys.stdin.readline().split()) MI return map(int, sys.stdin.readline().split()) map(int, sys.stdin.readline().split()) map int sys.stdin.readline().split() sys.stdin.readline().split sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline split def LI():
    return list(map(int, sys.stdin.readline().split())) LI return list(map(int, sys.stdin.readline().split())) list(map(int, sys.stdin.readline().split())) list map(int, sys.stdin.readline().split()) map int sys.stdin.readline().split() sys.stdin.readline().split sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline split def main():
    N, K = MI()

    i = 1
    while K ** i <= N:
        i += 1
    print(i) main N, K = MI() N MI() MI K i = 1 i 1 while K ** i <= N:
        i += 1
     K ** i <= N K ** i K i N i += 1 i 1 print(i) print i main() main def II():
    return int(sys.stdin.readline()) def II():
    return int(sys.stdin.readline()) II def LI():
    return list(map(int, sys.stdin.readline().split())) def LI():
    return list(map(int, sys.stdin.readline().split())) LI def MI():
    return map(int, sys.stdin.readline().split()) def MI():
    return map(int, sys.stdin.readline().split()) MI def main():
    N, K = MI()

    i = 1
    while K ** i <= N:
        i += 1
    print(i) def main():
    N, K = MI()

    i = 1
    while K ** i <= N:
        i += 1
    print(i) main
#!/usr/bin/env python3
import collections as cl
import sys


def II():
    return int(sys.stdin.readline())


def MI():
    return map(int, sys.stdin.readline().split())


def LI():
    return list(map(int, sys.stdin.readline().split()))


def main():
    N, K = MI()

    i = 1
    while K ** i <= N:
        i += 1
    print(i)


main()
