It's correct and I guess it wasn't that hard. Next time you should post your results along with the assignment.

05-29-2011

Needle_Scratch

my code is correct? or what

05-29-2011

phantomotap

Quote:

Next time you should post your results along with the assignment.

Out of curiosity, if that is the way you feel, why did you do it for him this time?

Soma

05-29-2011

Needle_Scratch

so , what about your code?

is it true ?

05-29-2011

phantomotap

O_o

If you know that the recursive version is correct, why don't you just compare the results of both versions up to 12 or 13 or so?

Soma

05-30-2011

kmdv

Quote:

Originally Posted by phantomotap

Out of curiosity, if that is the way you feel, why did you do it for him this time?

I did not want to see next thread with a simple question, dragging on forever, instructing the newcomer how he should ask questions the smart way. Anyway, I did not avoid it, cuz it already reaches the 10th reply.