A generator

Report a typo

Let's say you want to create a generator yielding the names of all csv files in my_dir and print them. Put the lines of code in the correct order. Don't forget about the indentation.

Reorder lines using drag or arrows. Adjust indentation with left buttons
                generator = glob.iglob("my_dir\\*.csv")
              
                import glob
              
                for item in generator:
              
                print(item)
              
___

Create a free account to access the full topic