Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Speedy category for The Ship Teams by itheklon
def two_teams(sailors):
team_1, team_2 = [], []
for item in sailors:
team_2.append(item) if 20<=sailors[item]<=40 else team_1.append(item)
return[sorted(team_1),sorted(team_2)]
Oct. 16, 2018
Comments: