RE: [Golfing] Collatz Conjecture 08-21-2015, 06:23 PM
#9
Code:
#include <iostream>
int main(){int n;std::cin>>n;while(n>1){n%2==0?n/=2:(n/=3)+1;std::cout<<n<<" ";}return 0;}110 bytes
I just started c++. Tried my best.
If you have suggestions, I'd be glad to hear it.
![[Image: dHJ4Beo.gif]](http://i.imgur.com/dHJ4Beo.gif)
Hidden Lesson: Reactions are always instinctive whereas responses are always well thought of.










![[+]](https://sinister.ly/images/modern/collapse_collapsed.png)