in reply to one liner - open file and read

$ wc -l < in.file

Replies are listed 'Best First'.
Re^2: one liner - open file and read
by TomDLux (Vicar) on Oct 07, 2010 at 20:26 UTC

    Don't re-direct; wc accepts a filename argument, or a list of filenames.

    wc -l in.file # also check out when multiple files match the pattern ... wc *.dat

    As Occam said: Entia non sunt multiplicanda praeter necessitatem.

      I know what wc is capable of.

      Hence the redirect.

      Run it with and without the redirect, and compare it to the output of the OP.

        Thank you for that! I didn't know about that trick.