invaderzard has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl use Modern::Perl; use File::Slurp qw/read_file write_file/; my $pfaminput ='D://ARP//Downloads//Trembl//toxinpospf.txt'; my $seedinput ='D://ARP//Downloads//PFACFULL.txt'; #open OUTPUT, ">", 'D://ARP//Downloads//trembl//Toxin-NegativeACClist. +txt'; #select OUTPUT; while (<$pfaminput>){ my $pfam = $_; print $pfam; #while (<$seedinput>) { # my $blah = substr $_, 0, 5; # if ($blah=<$pfaminput>) { #print $_; # } # #} }
Hi all. When I execute this code, I get: readline() on unopened filehandle at <insertprogramnamehere> line 9
This is my line 9
while (<$pfaminput>){Why is this? Please help and many thanks!
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: readline() on unopened filehandle
by Corion (Patriarch) on Sep 09, 2012 at 11:23 UTC | |
Re: readline() on unopened filehandle
by NetWallah (Canon) on Sep 09, 2012 at 14:11 UTC | |
Re: readline() on unopened filehandle
by aitap (Curate) on Sep 09, 2012 at 15:13 UTC |
Back to
Seekers of Perl Wisdom