tamaguchi has asked for the wisdom of the Perl Monks concerning the following question:
The ouput I get is following:#!/usr/bin/perl -w use strict; my $path='C:/dataset/'; my @sign_arr=('A1', 'A2', 'A3','A4', 'A5', 'A6', 'A7', 'A8', 'A9'); foreach (@sign_arr) { if(defined (my $filename=(glob("$path*$_*.pkl")))) {print "$filename $_\n"} else {print "not found $_\n";} }
2006-08-21 Retitled by holli, as per Monastery guidelines
Original title: 'Glob strange bahavor'
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Glob strange behavior
by jhourcle (Prior) on Aug 21, 2006 at 12:50 UTC | |
|
Re: Glob strange bahavor
by Sidhekin (Priest) on Aug 21, 2006 at 12:57 UTC | |
by ikegami (Patriarch) on Aug 21, 2006 at 14:52 UTC | |
|
Re: Glob strange behavior
by un-chomp (Scribe) on Aug 21, 2006 at 13:40 UTC | |
|
Re: Glob strange behavior
by cdarke (Prior) on Aug 21, 2006 at 12:46 UTC | |
|
Re: Glob strange behavior
by calin (Deacon) on Aug 21, 2006 at 15:41 UTC | |
by Anonymous Monk on Aug 22, 2006 at 03:15 UTC | |
|
Re: Glob strange behavior
by mobby_6kl (Novice) on Aug 21, 2006 at 22:22 UTC | |
|
Re: Glob strange behavior
by johnnywang (Priest) on Aug 21, 2006 at 23:37 UTC | |
by graff (Chancellor) on Aug 22, 2006 at 02:24 UTC | |
by Anonymous Monk on Aug 22, 2006 at 13:30 UTC | |
|
Re: Glob strange behavior
by Anonymous Monk on Aug 22, 2006 at 13:40 UTC |