那位高手能帮忙下面问题,有报酬。联系我:shangyida@gmail.com
Use pico to create a UNIX file in your bin directory called accessions containing just a list of simple accession numbers separated by carriage returns (and nothing else!) e.g.
A10369
X45345
P12353
M15668
Z89376
Write a Perl program to open a file from the command line, read each line of the accessions file, add a .seq suffix to every accession number, and write the resulting “accession.seq” out to a new file ending with the suffix .list (e.g. accessions.list). The contents of the new file will look like this:
A10369.seq
X45345.seq
P12353.seq
M15668.seq
Z89376.seq
To get a filename from the command line (e.g. perl Q2.pl accessions), you simply shift()the first element of the @ARGV default array. This is so common that you do not even have to write @ARGV; just do: $filename = shift;
$filename should now contain the “accessions” file name.
Show BOTH source code and the accessions.list file.
Add a Reply