Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A program is to be written to simulate spinning the wheel below. The spinner bel

ID: 3834670 • Letter: A

Question

A program is to be written to simulate spinning the wheel below. The spinner below has 3 sections such that sections 1 and 2 are of equal size and section 3 is twice as big as section 1. Which of the following instructions will correctly generate random numbers to simulate the behavior of the spinner? What are the final values of num1 and count when the code segment below has completed execution? Num 1 = 3, count = 5 num 1 = 3, count = 6 num1 = 15, count = 5 num1 = 15, count= 6 Consider the code segment below. What does the sprite say when me = 20 and you = 20? Tie score. You Win! You Lose! You Lose! Tie score.

Explanation / Answer

16)Spinner will give us either 1 , 2, or 3
But since 3 is bigger , we will generate numbers from 1 to 4 and so when 4 comes we will treat it as 3
b) Is the answer

17) Count will become 6 that right , but num1 is increasing by 3 at every increment of count by 1
count. = 1 , num = 3
count. = 2 , num = 6

count. = 3 , num = 9
count. = 4 , num = 12

count. = 5 , num = 15

count. = 6 Loop exits , So num = 15

Option d is the answer

18) d) You Lose! Tie Score


Because else is also executed and last Instruction is also executed

Let me know if there is any doubt/concern.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote