You are viewing a single comment's thread. Return to all comments →
There's a mistake in multiple places in problem description (n should be the number of non-zero stones, but it's the number of all stones). Python3
n -= 1 solutions = set(a*i + b*(n-i) for i in range(n+1)) return sorted(solutions)
Seems like cookies are disabled on this browser, please enable them to open this website
Manasa and Stones
You are viewing a single comment's thread. Return to all comments →
There's a mistake in multiple places in problem description (n should be the number of non-zero stones, but it's the number of all stones). Python3