0
(Python) Plz help with this collatz conjunction using two input and finding the highest length between the first and last input
Lower_bound = int(input()) Upper_bound = int(input()) Length = 1 while lower_bound != 1: while lower_bound <= upper_bound: If lower_bound % 2 == 0: lower_bound = lower_bound // 2 else: lower_bound = lower_bound * 3 + 1 length += 1 lower_bound += 1 print(lower_bound) print(length)
1 Réponse
0
Jaime- Brawl Stars it looks like you are missing some code ... Please show us your full code by copy and pasting in a python development code-bit...