Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Creative category for Funny Addition by fed.kz
from random import choice
from operator import add
from functools import reduce
def checkio(data):
if data[0] == data[1]: return choice(data) * 2
if all(number < 0 for number in data): return reduce(add, data)
if any(number < 0 for number in data): return sum(data)
result = 0
for _ in range(data[0]):
result += 1
for _ in range(data[1]):
result += 1
return result
Oct. 1, 2018