[Community Puzzle] Halting sequences



Send your feedback or ask for help here!

Created by @Waffle3z,validated by @java_coffee_cup,@Alain-Delpuch and @R2B2.
If you have any issues, feel free to ping them.


Is there some kind of trick to figuring out if something will end up looping? Because I don’t get how to solve this without some brute forcing. I get that you should keep track of the answers from the previous pairs, but on the larger number sets I get stack overflow error.


Yes, there is definitely a trick :slight_smile:
Some of the testcases involve huge numbers and the length of the loop can be quite large so I don’t think a simple simulation could work here. This puzzle is more math than coding.
Try to figure out what specific property a and b have if they result halt. The example in the description and the other IDE test cases help a lot!