Project Euler 686 - Powers of Two

Official link: https://projecteuler.net/problem=686

Thought Process

When dealing with huge numbers it's sometimes easier to deal with logs of those numbers!

Iterate through j, if the inequality is true we have found another number such that 2^j starts with 123, hence we increase a counter and we stop once the counter = 678910

Interactive Code

Enter a number (yourinput)

Code will output p(123, yourinput)