Help in C with the collatz problem.
I have wrote the code in Python and it works, but in C I have some problems.
Can someone help me, please? This is my code: Quote:
|
N will never be 1; thus the app will never exit the while-loop.
|
Also, you should be using [code] tags, rather than [quote], to preserve indentation.
|
Quote:
Kevin Barry PS It could be that N needs to be copied when used in the loop. |
Quote:
|
Quote:
Quote:
|
All times are GMT -5. The time now is 04:53 AM. |