in reply to Re: compare previous and present hash key values
in thread compare previous and present hash key values

It's neighboring keys actually. So to begin, i will start with the first key in the hash and compare with the second, then the second with the third etc. I tried your code but it says undefined subroutine retrieve_key.

Best regards.
  • Comment on Re^2: compare previous and present hash key values

Replies are listed 'Best First'.
Re^3: compare previous and present hash key values
by choroba (Cardinal) on Jan 11, 2014 at 15:33 UTC
    Yes, you have to write your_sorting_routine or retrieve_key yourself. In Perl, there is no "neighbouring" hash key - hash keys have no defined order, as has been already pointed out.
    لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ
      Does using array make my life any easier ? please see my last response to user "Rolf"