I'm trying to solve a problem from a website called Project Euler. The thing is that I already have a way how to solve it, but the problem is that the array "Number[1000]" keeps producing weird numbers to the millions per index even though it's supposed to only track numbers that have a sum less than or equal to 1,000 and then stores them to a index minus one.
Here's my code:
How come this is happening?
Here's my code:
Code:
//Removed
Last edited: