in reply to Re: Dealing with Hash Table
in thread Dealing with Hash Table
Eliya, I liked your first solution. All it needs is a way to initialize the top 20 array with the first 20 data points. Instead of checking if $e is not defined check if @top has fewer than 20 elements.
if ( @top < 20 || $score > $e->[1] ) {
|
|---|