Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^2: glob quietly fails

by QM (Parson)
on Oct 15, 2012 at 15:14 UTC ( #999102=note: print w/replies, xml ) Need Help??


in reply to Re: glob quietly fails
in thread glob quietly fails

see Re: Hexamer combination from 3mers. about Algorithm::Combinatorics.

Understood. But that doesn't solve the "array of arrays, 1 from each" problem. A shorter version of the OP glob spec would be

@x = (1..2); @y = qw(one two); @z = qw(Amy Bob); @xyz = (\@x, \@y, \@z); $glob = join( ',', map { '{' . join( ',', @$_ ) . '}' } @xyz ); print "$glob\n"; # prints '{1,2},{one,two},{Amy,Bob}'

I don't know of a module that can emulate glob on that.

-QM
--
Quantum Mechanics: The dreams stuff is made of

Replies are listed 'Best First'.
Re^3: glob quietly fails
by martin (Friar) on Oct 15, 2012 at 16:58 UTC

    Actually I think your iterator solution is not half bad. It could work very well where nested foreach loops are not an option.

    I'd drop the redundant array_limits array, however.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://999102]
help
Chatterbox?
[shmem]: discovered a fuel tank leakage at my second hand motorbike. Some bloke drove a screw too long through the fairing
[shmem]: hard to fix, and plans wrecked. And more... won't tell.
[shmem]: the leakage has been "fixed" with a piece of bycicle tube. Bleargh.
[karlgoethebier]: shmem: yes. my first ride tomorrow is questionable because of lumbago. shit
[shmem]: But! the bloke wasn't me, at least.

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (11)
As of 2017-06-25 20:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (570 votes). Check out past polls.