This one is simple: take a list of skating scores, drop the highest and lowest, and take the average of the remaining to get the actual score. Perl 6 shines here, with split
and the reduction meta operator making for elegant code. But I've hit on a weird snag:
$score = $score - (@scores.min () + @scores.max ());doesn't compile. Err... but
$score = $score - (@scores.min() + @scores.max());does. Is space before function parameters no longer allowed?