Question #220638

write a program that displays the following number sequence. make sure there is no extra comma.(2,2.25,2.50,2.75,..,4) in python loop


Expert's answer

i=2
while i<4:
    print(i, sep='', end=', ', flush=True)
    i+=0.25
    
print(4.0)
LATEST TUTORIALS
APPROVED BY CLIENTS