2 days ago I started solving the problems on https://projecteuler.net/ recommended to me by @AlmondSauce and I already regret knowing python, a relatively simple calculation -ish took roughly 4 hours to compute

  • 0
    @groxx yeah I figured out that my brute force approach was horrible, I saw some beautiful implementations after submitting the answer, now i am implementing better algorithms to try and solve them better
  • 1
    Just as a quick edit to amplify my genius, I found an algorithm that helped me finish the calculation in under 30 minutes : /
  • 4
    @groxx i usually just throw the problems into haskell and it magically finishes super fast, idk how
  • 2
    If you take more than 1 minute(even on python) to solve a problem, that means your algo can be further optimized. I've solved nearly 200 of them and almost all of them can be solved within 15 seconds
  • 1
    Which specific problem are you talking about here? I never got past number 40 or so, and there are a few in the middle I have not tackled yet…
  • 0
    @SomeNone I believe it was the sum of every prime under 2 million I think
  • 1
    @hamolicious Oh, that one, Euler#10. Sieve an array with the Eratosthenes algorithm, then sum up the non-zero items. Should run in well under a second.
Add Comment