<reponame>daberg/dislog<filename>doc/lst1-exhaustive.py<gh_stars>0
def exhaustive(alpha, beta, n):
    exp = 0
    power = alpha ** 0

    while power != beta:
        exp += 1

        if exp == n:
            return None

        power *= alpha

    return exp

def exhaustive(alpha, beta, n):
    exp = 0
    power = alpha ** 0

    while power != beta:
        exp += 1

        if exp == n:
            return None

        power *= alpha

    return exp