I wish that, what I input in command line of python/ipython, can also be redirect to a file. Also, I wish to capture the output text to a file.
Is there any option, or internal function could help on this?
I wish that, what I input in command line of python/ipython, can also be redirect to a file. Also, I wish to capture the output text to a file.
Is there any option, or internal function could help on this?
Them simplest way, as "furas" already said is the ">" and "<" symbols.
I'm using linux, but as I know, they work in windows too.
The syntax you want: python myfile.py < input.txt > output.txt