I was inspired to dig a little deeper into the issue raised in PR #13844, finding the exponent of integer `x` in `y`, More specifically, finding whether `y` is exactly `x**n`. I read
here that this problem has "no efficient solution". But I must be missing something, because if (in SymPy) we write `integer_log = lambda y, x: multiplicity(x, y)` that runs as the square of the number of digits of y. Although multiplicity doesn't exactly give what we are looking for it is not hard to modify it so it does (and it runs in `O(d**2)` where d is the number of digits)...am I misunderstanding something about the complexity measure or the nature of the problem?
/c