【发布时间】:2020-05-05 11:07:49
【问题描述】:
我正在寻找一种方法来从 itetools 库中实现类似 python 的组合函数 product,在 lua 中使用 repeat 参数。
我找到了这个库
https://github.com/aperezdc/lua-itertools/blob/master/itertools.lua
但不确定这是否对我有用,因为我在那里找不到 product 函数
实现这种功能的算法是什么?
【问题讨论】:
标签: lua combinatorics