#!/usr/bin/perl # your code goes here use warnings; use 5.14.2; my @input = sort split ' ', <>; say ($input[0] * $input[1] + $input[2] * $input[3]);