Say i want to read standard input from a file rather than the keyboard. For example:
./myprog < in.txt
I've tried putting '< in.txt' in the program arguments and other places but it doesn't work. Putting '> out.txt" works fine though.
Are there any tricks i can use to do this?
stdin redirection possible?
-
- CodeLite Curious
- Posts: 8
- Joined: Thu Nov 25, 2010 4:10 am
- Genuine User: Yes
- IDE Question: c++
- Contact:
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: stdin redirection possible?
I dont think sojazztickets wrote:Are there any tricks i can use to do this?
Eran
Make sure you have read the HOW TO POST thread