I am currently re-learning everything about coding. (haven't done it in 3 years)
Anyways, as I am working on problem 2 @ projecteuler.net I am having a problem that I know has a quick fix. I am having a problem with these two lines.
1 2
prev2 = prev1;
prev1 = i;
Both are declared but i'm getting the "left operand must be l-value"
what do you mean by answer += i, is += only used for comparisons.
please explain to me if += has other uses unrelated to comparisons since I don't know any
I am looking over my code and realized that I will never get out of if(i == prev1 + prev2) because I am setting i = prev1 in that loop. Not sure how to go about rewriting this besides scrapping it. Heh.