in reply to Re^3: How to pass a variable to a subroutine
in thread How to pass a variable to a subroutine
Results@FN = split(/\=/, $LINE); push(@FILE_NAME, @FN[1]); foreach my $FN_SPLIT (@FILE_NAME) { chomp $FN_SPLIT; print "This is the fn_split variabl +e: $FN_SPLIT\n\n"; find ( sub { my $FOUND_FILE = $_; chomp $FOUND_FILE; print "This is the FOUND_ +FILE variable: $FOUND_FILE\n\n"; if ( $FOUND_FILE =~ /($FN +_SPLIT)/ ) { print "============== +==================================================\n"; print "MATCH MATCH MA +TCH $FN_SPLIT : $FOUND_FILE MATCH MATCH MATCH\n"; print "============== +==================================================\n"; } else { print "$FOUND_FILE do +es not equal: $FN_SPLIT\n\n"; } }, $SEARCH_DIR ); }
This is the fn_split variable: 08ptr00 This is the FOUND_FILE varible: . . does not equal: 08ptr00 This is the fn_split variable: 08r2t00 This is the FOUND_FILE varible: 08r3t00 08r3t00 does not equal: 08ptr00 This is the fn_split variable: 08ptr00 This is the FOUND_FILE varible: 08ptr00 08ptr00 does not equal: 08ptr00
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: How to pass a variable to a subroutine
by ikegami (Patriarch) on Dec 06, 2008 at 22:43 UTC | |
by learningperl01 (Beadle) on Dec 06, 2008 at 23:13 UTC | |
by ikegami (Patriarch) on Dec 07, 2008 at 00:28 UTC | |
by Anonymous Monk on Dec 07, 2008 at 22:26 UTC |