Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: command line perl reading from STDIN

by talexb (Canon)
on Jan 22, 2013 at 17:56 UTC ( #1014745=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    cat input_file.fq | \
    perl -ne '$s=<>;<>;<>;chomp($s);print length($s)."\n";' > output.txt
    
  2. or download this
    perl -ne '$s=<>;<>;<>;chomp($s);print length($s)."\n";' \
    <input_file.fq >output.txt
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1014745]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (7)
As of 2014-08-28 02:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (255 votes), past polls