Seperate each digit using %10 to find ones digit, then divide by 10 to shift to next digit. For some reason pow() from math.h wasn't working for me, so I just wrote a function to find the 5th power for me.
Not being smart, it takes about 5m30 seconds to solve. Once I got into the forums, someone had a proof that there are no solutions past a smaller number, which brought the runtime down to 0.028 seconds.
PE030_c
Return to list of solutions
Comments (0)
You don't have permission to comment on this page.