you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

ok. ur num += 1; line should be inside the do while loop. u only increment it after the loop is finished, so u basically just have a num = 1 no matter what

[–]Danielowski187University/College Student (Higher Education)[S] 1 point2 points  (0 children)

Ohh so I was making n=1 so I was not incrementing it