Best writers. Best papers. Let professionals take care of your academic papers

Order a similar paper and get 15% discount on your first order with us
Use the following coupon "FIRST15"
ORDER NOW

Maocion Chapiced By the Collate Conjecture for wig an that Console output will be displayed here

Maocion Chapiced By the Collate Conjecture for wig an that
Console output will be displayed
here
7 0tastiwith any number. If the number is divisible by 3,
B divid+ it by 3. otherwise, add 2 to the number, Eventually,
i Led matter what number you begin with, this series will run
10 bares lies 2. If it gunn into 1 it will careat 1-3 forever.
1101: thing inc6 2, it will ropont 2-4-6 Eggevery
12
13 for example: imagine we started with the number 5:
1 15 As mot divisible by 3. no 5 + 2 – 70
s of im not divisible by 3. so 7 0 2 – 9
16 #9 1= divisible by 3. 10 9 / 3 2 3
17 #2 15 divisible by 3. so 3
18#4
19 DBtort with 5, this sequence converges ball in 4 iterations:
20 45 -2 7, 7 +2 9 9 -3 3, 3 3 1.
23 Wecite a function called joyner. joyner should have one
23 #parameter, an integer. It should return the number of
24 Bitoration required to reach either 1 or 2 for the first
26
20 Add Your code herel
29
32 Below ace some lines off code that will test your function.
33 You can change the value of the variable() to test your
34 function with different inputs.
35
36 Off your function works correctly, this will originally
37 Cprint: 4, S, and 10, each on their own lines.
30 print ( joyner (5] ]
39 print (joyner (15)1
40 print (joyner (29) )
< Previous

 
Looking for a Similar Assignment? Order now and Get 10% Discount! Use Coupon Code "Newclient"