sub clock { my $minutes = shift; my $hh = int($minutes/60); my $rest = abs($minutes - $hh*60); return sprintf ("%d:%02d", $hh, $rest); }