How many times the following loop execute in python
c=0
while c<20:
c+=2
Answers
Answered by
0
The following loop will execute 9 times in Python. As there are 9 multiples of 2 between 0 and 20.
PROGRAM:
Input:
c = 0
while c<20:
c += 2
print(c)
Output:
2
4
6
8
10
12
14
16
18
Similar questions
History,
16 days ago
Physics,
16 days ago
Social Sciences,
1 month ago
English,
9 months ago
Math,
9 months ago