On the Subject of Integer Trees
Contrary to binary trees, integer trees grow upwards and are actually explained...
- For both numbers on the top and bottom of the module, do the following:
- If the number is even, divide it by two.
- Otherwise, multiply it by three, and add one.
- Repeat those steps until both numbers equal one.
- Take the highest shared value between the two sets of numbers and multiply it by the total number of rows in the two sets. Each new number is a row (including the first number and 1).
- Submit that number by using the arrows to adjust the number on the display and the display itself to submit.