http://www.perlmonks.org?node_id=334100


in reply to Can you spot the problem?

Root node updated. Well, for one, that second if needs curly braces. This isn't C after all. ; )

Just to nitpick with it, $a and $b really shouldn't be used as they're used for sort.