magical
7373859412
instead of lists, construct a tower of nested generators. i think this is equivalent to a recursive backtracking solution. since the input doesn't contain 0 we can check for <goal in the intermediate layers, and ==goal at the end. |
||
---|---|---|
.. | ||
input | ||
sample1.in | ||
sol.py |