in reply to Sort never returns data in right order

@keys = sort {$interface_bytes{$a} <=> $interface_bytes{b}} keys %interface_bytes;

That line doesn't look right to me. Perhaps you needed $b instead of just b.

Replies are listed 'Best First'.
Re^2: Sort never returns data in right order
by jsmith118 (Novice) on Sep 05, 2017 at 14:53 UTC

    Thank you.. I looked at that for a day and never saw it.

      You should have gotten a warning ("Uninitialized used of ...") unless you happened to have a key named b. Always use use strict; use warnings qw( all );!!!