<?xml version="1.0" encoding="windows-1252"?>
<node id="1001667" title="Re: sort hash of arrays of arrays" created="2012-10-31 10:03:02" updated="2012-10-31 10:03:02">
<type id="11">
note</type>
<author id="171588">
BrowserUk</author>
<data>
<field name="doctext">
&lt;blockquote&gt;&lt;i&gt;So this is a 3-dimensional array...&lt;/i&gt;&lt;/blockquote&gt;

&lt;p&gt;Not the way you shown it isn't:
&lt;code&gt;
@inner1 = (0, 1, 2);
@inner2 = (1, 4, 7);
@inner3 = (2, 5, 8);
@inner4 = (6, 7, 9);

@array1 = (@inner1, @inner2, @inner3, @inner4);;

print @array1;;
0 1 2 1 4 7 2 5 8 6 7 9

@array2 = (@inner1, @inner2, @inner3, @inner4);;

print @array2;;
0 1 2 1 4 7 2 5 8 6 7 9

%hash = (array1, @array1, array2, @array2);;
pp \%hash;;
{
  "0"      =&gt; 1,
  "1"      =&gt; 4,
  "2"      =&gt; 5,
  "4"      =&gt; 7,
  "5"      =&gt; 8,
  "6"      =&gt; 7,
  "7"      =&gt; 9,
  "8"      =&gt; 6,
  "9"      =&gt; "array2",
  "array1" =&gt; 0,
}
&lt;/code&gt;

&lt;p&gt;If that's the way you are building it in your program; it is little wonder your attempt to sort it didn't work?

&lt;div class="pmsig"&gt;&lt;div class="pmsig-171588"&gt;
&lt;hr /&gt;
&lt;font size=1 &gt;
&lt;div&gt;With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'&lt;/div&gt;
&lt;div&gt;Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.&lt;/div&gt;
&lt;div&gt;"Science is about questioning the status quo. Questioning authority". &lt;/div&gt;
&lt;div&gt;In the absence of evidence, opinion is indistinguishable from prejudice.
&lt;p align=right&gt; [http://thebottomline.cpaaustralia.com.au/|RIP Neil Armstrong]&lt;/p&gt;&lt;/div&gt;
&lt;/font&gt;

&lt;/div&gt;&lt;/div&gt;font size=1 </field>
<field name="root_node">
1001665</field>
<field name="parent_node">
1001665</field>
</data>
</node>
