You are viewing a single comment's thread. Return to all comments →
Here is my Python solution!
def stones(n, a, b): finals = [] for first in range(n): finals.append(first * max(a, b) + (n - first - 1) * min(a, b)) return sorted(list(set(finals)))
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 →
Here is my Python solution!