# 対数の整数部分 import math def main(): N,M = map(int, input().split()) print(int(math.log(M, N))) if __name__ == "__main__": main()