|
 |
In article <4a8bba80$1@news.povray.org>,
Invisible wrote:
> Warp wrote:
>
>> 'cat' is a program for concatenating files. It's used like:
>>
>> cat file1 file2 file3 > concatenated_files
>>
>> Your program does not fulfill this role.
>>
>> (Some people abuse 'cat' to concatenate one single file with nothing,
>> but that doesn't mean that the role of 'cat' is anything else than
>> concatenating files.)
>
> Interesting. I thought it was for concatenating a file to stdout...
It is. :-) In the same order in which they are read.
> Alrighty then:
>
> import System.Environment
>
> main = do
> args <- getArgs
> mapM_ (\arg -> readFile arg >>= putStr) args
>
> That seems to work.
>
> I'm guessing the real cat program also has assorted command-line
> switches as well though?
Your cat has a disease, common in recently seen cats, the makes it
ignore the stdin.
Post a reply to this message
|
 |