Justin Whear:

> alias Tuple!(int, string) P;
> assert(equal( 
>       cartesianProduct([1, 2], ["a", "b"]),
>       [ P(1, "a"), P(1, "b"), P(2, "a"), P(2, "b") ]
> ));
> 

See std.range.lockstep and std.range.zip.

Bye,
bearophile

Reply via email to