Lucas/Carmichel Numbers
Note: this is an old blog post from my old and closed down blog but, you know, recycling is good.
One of my favorite Youtube channels are Numberphile and today I watched a short talk about Lucas-Carmichael numbers.
It look like a perfect problem to solve in Haskell so I created the following little program producing all LC numbers less than 100000.
|
|
There are for certain better ways to solve it but I think it is a neat and clear solution.
I think they forgot to mention it the video that the number must be odd and not contain any squared prime factors. Found that out on Wikipedia.
/Calle