Strategies for debugging

Print out intermediate information

Explain your code to someone else

Explain the code to rubber ducky

Comment your code

Name variables descriptively

Test early - try to break, and see if you can find inputs for which the program takes a long time

Separate your program into various functions that do specific things, and can be tested separately

First solve an easier case

In [3]:
N(log(26^12,2))
Out[3]:
56.4052766176931
In [4]:
N(log(2^56,10))
Out[4]:
16.8576797571829