Message276860
Lucas, I largely agree, but it is documented that the various combinatorial generators emit items in a particular lexicographic order. So that is documented, and programs definitely rely on it.
That's why, in an earlier comment, Terry suggested that perhaps `product()` could make a special case of its (and only its) first argument (and only when repeat=1). Each element of the first iterable is needed only once (although it may copied into any number of outputs), so there's no actual need to make a tuple of it first. The implementation is just simpler and clearer by treating all arguments alike.
Which is a good enough reason for me - and the "use cases" for an unbounded first argument look exceptionally weak to me. |
|
Date |
User |
Action |
Args |
2016-09-18 00:09:15 | tim.peters | set | recipients:
+ tim.peters, rhettinger, terry.reedy, falsetru, nneonneo, eric.araujo, Sumudu.Fernando, yegle, Lucas Wiman |
2016-09-18 00:09:15 | tim.peters | set | messageid: <1474157355.23.0.221299562666.issue10109@psf.upfronthosting.co.za> |
2016-09-18 00:09:15 | tim.peters | link | issue10109 messages |
2016-09-18 00:09:14 | tim.peters | create | |
|