print loop output in one line python using for loop code example Example: making lists with loops in one line python print([i for i in range(10)])