logoalt Hacker News

tkgally01/22/20251 replyview on HN

Interesting! What do you do when you try to factor a large number that doesn't yield to any of your mental factoring techniques? It might be prime, after all, or composite with only large prime factors. Do you give up after a while? Run it through a factoring program? Keep plugging away until you get to the number's square root?


Replies

dhosek01/23/2025

With the odometer I have a time limit to factor the number (around one minute on the highway, up to four on surface streets). I usually have no problem factoring a four digit number (time in 24-hour format) within the minute given, especially since the worst case scenario would be 22:09=47×47. When factoring, it’s less about recognizing the primes as the key composites once you get down to four digits or less, which usually happens surprisingly quickly.