* Idea: cache best(i, capacity). The only change from 0/1 knapsack is that "take" recurses * on (i, capacity - weight[i]) instead of (i + 1, ...). The state count is the same. * Time complexity: O(n * ...