in reply to Re^2: Printing a Hash Slice problem
in thread Printing a Hash Slice problem

[-1] is a negative array index, which lets you count from the other end of an array. $array[-1] is the same as [reverse @array]->[0] or $array[$#array]

<=> is a comparison operator for numbers, similar to cmp for strings. (see perlop or the sort documentation)