davidfilmer has asked for the wisdom of the Perl Monks concerning the following question:
sub my_filter { my ($hash) = @_; return [ sort {$b <=> $a} keys %{$hash}; #Reverse sort ]; }
perl complains of a syntax error near "};" but I don't see it! My only change was tr/%$hash/%{$hash}/ (the Damian way), but it fails either way.
I seek enlightenment
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: syntax error - WHERE?
by BrowserUk (Patriarch) on Feb 12, 2014 at 01:22 UTC | |
|
Re: syntax error - WHERE?
by toolic (Bishop) on Feb 12, 2014 at 01:29 UTC | |
|
Re: syntax error - WHERE?
by LanX (Saint) on Feb 12, 2014 at 01:27 UTC |