The Collatz function is not very elegant in that the odd case is always even because is odd, so it is always predictably followed by a division by two. This is not the case for the even case, where the result can be either even or odd.
A much more elegant formulation is to immediately also divide by two when the number is odd:
Video 1.
Any Poll's a Goal by Internet Historian
. Source.
Video 2.
Gavin Belson Signature Scenes from Silicon Valley
. Source.
Integer algorithm by Ciro Santilli 37 Created 2025-10-14 Updated 2025-10-27
We define an "integer algorithm" as an algorithm that takes integer inputs and produces integer outputs.
There are to ways in which the Collatz conjecture can fail:
These are the only two options because if any sequence has an upper bound, it must sooner or later repeat an element, leading to a cycle.

There are unlisted articles, also show them or only show them.