in reply to Efficient but elegant Cross-Product iterator ?

I'm not sure from your description, but what you want sounds very much like Algorithm::Loops::NestedLoops, which takes subroutines to create loops and nests those to create the data structure (as another iterator).

  • Comment on Re: Efficient but elegant Cross-Product iterator ?

Replies are listed 'Best First'.
Re^2: Efficient but elegant Cross-Product iterator ?
by LanX (Saint) on Jun 20, 2020 at 21:22 UTC
    Thanks, pretty close but not exactly what I'm trying to achieve in the end.

    Some interesting ideas though.

    The code looks like written by an experienced C programmer.° ;)

    One point with "when" looks buggy, will need to install and test.

    Didn't know it's possible to use isa instead of ref to test for a CODE ref (?) Strange!

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery

    °) hey Tye, where are you? :)