Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
5-liner solution in Clear category for Number Guess by przemyslaw.daniel
def checkio(attempts):
a = sum([x[0] * 210 // x[1] for x in attempts[1:]])
b = sum([210 // x[1] for x in attempts[1:]])
r = [(b * x - a) % 210 for x in range(1, 101)].index(0)
return [[2, 3, 5, 7, 9][len(attempts) - 1], r + 1]
Sept. 24, 2016