Infosys interview question

how to make a for loop in python in one line.