On April 1st, one of the post on v2ex (An online community of developers and designers in China1) become viral. The post title is “Seeking Dates” and it is posted on April 1st, so most reactions of this post are pointing out that this is the “new trap” of the recruiters.
Here is the translation:
I am born and raised in Hangzhou. I am a science student at Zhejiang University … I hope to find a man can pass the following test. My Wechat ID is my Family name Lin followed with two prime number. The smaller prime number is in the front. The product of these two prime numbers 7140229933. If you can find my Wechat ID, I will sincerely date you. Bula bula bula …
Disregard if it is a joke, I think the question is interesting. So let’s solve it.
The idea is using Exhaustive Method (Brute Force Method) to find two prime factors. However, 7,140,229,933 is a relatively large number. To find all prime number could take a long time. Since 7,140,229,933 is the product of two prime, one of the numbers must smaller than the Square Root of it. Therefore the order of magnitude of range could reduce from $10^9$ to $10^4$. Here is my solution.
|
|
Output:
|
|
So the two prime number are 83777 and 85229.