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


in reply to Preserve the order in JSON

user786:

Inside a dictionary/hash, there's no meaning to the order of the keys. That's what it means to be unordered. If you want to maintain order, I'd suggest switching to an array. Arrays will maintain the order.

...roboticus

When your only tool is a hammer, all problems look like your thumb.