185k views
0 votes
What is output by the following code? Select all that apply.

C = 0
while (c< 11):
C = C+ 6
print (c)

User Annosz
by
6.4k points

1 Answer

4 votes

Answer:

The output of the following code is:

6

12

18

24

30

36

42

48

54

60

66

The code defines a variable C and assigns it a value of 0. It then enters a while loop, which will execute as long as the value of C is less than 11. Inside the loop, the value of C is incremented by 6. The loop then prints the value of C and continues until the value of C is no longer less than 11.

Each time the loop executes, the value of C is increased by 6, so the output of the loop is a series of numbers that are 6 units apart, starting at 6 and ending at 66.

Step-by-step explanation:

User SNce
by
6.7k points