Question 4

Last Updated :
Discuss
Comments

What is the output of the following code?

X=5;

while X>0:

      X=X-1;

      print(X)

5  

4  

3  

2  

1  

0

4  

3  

2  

1  

0

5  4  3  2  1

4  3  2  1  0

Share your thoughts in the comments