KnowledgeBoat Logo

Computer Science

Predict the output of the following code fragments:

for y in range(500, 100, 100):
    print (" * ", y)

Python

Python Control Flow

8 Likes

Answer

This code generates No Output.

The for loop doesn't execute as range(500, 100, 100) returns an empty sequence — [ ].

Answered By

3 Likes


Related Questions