in reply to Re: Why is grep not searching for contents?
in thread Why is grep not searching for contents?

I just gave a sample example,I actually have an array with lot of files,how can open a file handle for such situation

my @files;#I need to have an array that has a file handle for each fil +e my $folder="oem";

Replies are listed 'Best First'.
Re^3: Why is grep not searching for contents?
by John M. Dlugosz (Monsignor) on Apr 30, 2011 at 10:15 UTC
    When learning the basics, you might try looking closely at just one thing at a time. Rather than having your whole script fall apart, look at what just one call or construct is doing. Understand what it does and how it should be used. Then look at the larger context it is being used in. Try printing the arguments (use Data::Dumper if they are not simple) to make sure you are feeding it what you intended. Make a miniature test calling just that one thing with the parameters ready to go. If that's OK, then shift your focus to how those values are being prepared for that use.
Re^3: Why is grep not searching for contents?
by Anonymous Monk on Apr 30, 2011 at 04:18 UTC

    Never mind,just added a for loop