how to print text file on python by time code example Example: python output to text file $ python my_program.py > output.txt