Results 1 to 2 of 2
Hi,
Just wondering, is there a fundamental difference between:
cat textInput | ./prog_expecting_input
and
./prog_expecting_input < textInput
and
cat textInput > ./prog_expecting_input
Thanks in advance....
- 10-11-2010 #1Just Joined!
- Join Date
- Oct 2010
- Posts
- 1
Basic Shell/Script Question
Hi,
Just wondering, is there a fundamental difference between:
cat textInput | ./prog_expecting_input
and
./prog_expecting_input < textInput
and
cat textInput > ./prog_expecting_input
Thanks in advance.Last edited by roswell88; 10-11-2010 at 03:07 PM.
- 10-11-2010 #2
Well, the last one won't work. The redirection operator > can only be used to redirect output into a file, not to a program. I think the other two are equivalent.
"I'm just a little old lady; don't try to dazzle me with jargon!"


Reply With Quote