C++ Project Euler #12 optimization- highly divisible triangular number
The code takes far too long to complete (over 10 minutes). Is there any way to optimize the run-time? And, and to make it more elegant?
So I only need to iterate up to half of the limit. But how can I implement that into my code? to only iterate up to half as many factor. Thankyou?
C++ Project Euler #12 optimization
The code takes far too long to complete (over 10 minutes). Is there any way to optimize the run-time? And, to make it more elegant?
So I only need to iterate up to half of the limit. But how can I implement that into my code? to only iterate up to half as many factor. Thankyou
Project Euler #12 - highly divisible triangular number
The code takes far too long to complete (over 10 minutes). Is there any way to optimize the run-time and to make it more elegant?
So I only need to iterate up to half of the limit. But how can I implement that into my code to only iterate up to half as many factor?
- 13.1k
- 1
- 35
- 76