Answer:
The missing code is rolls < 100 && sixes < 25
Step-by-step explanation:
From the question, the while loop is expected to terminate (stop rolling) with either rolls reaches 100 or sixes reaches 25. This means we expect if one of the two conditions
- rolls < 100
- sixes < 25
is not met, the while loop should stop and print the rolls and sixes.
To achieve the aim, we use logical operator AND, && , to join the two conditions in the while loop.
With AND logical operator, if rolls reaches 100, the condition rolls < 100 will return false.
- So false && true -> false (While loop stop)
If sixes reaches 25, the condition sixes < 25 will return false.
- So true && false -> false (While loop stop).