Do you know where your variables are? | |
PerlMonks |
Re: Re: "Intelligent" array joiningby ngomong (Sexton) |
on Feb 05, 2004 at 22:03 UTC ( [id://326906]=note: print w/replies, xml ) | Need Help?? |
Well, you see... I'm not trying to sort based on numerical order. I'm trying to sort based on the original order of the arrays. Let's try this again: The output would then be: Here, fish should come before mouse, and before bird. So, I'm not sorting numerically, and I'm not sorting alphabetically... I'm trying to preserve the order of the original arrays... To make this (perhaps) a little more clear, here's my specific problem. I'm taking data sets, with questions, and each question has a unique identifier, a GUID. For the most part, for each data set, the GUIDs will be in the same order, but every now and then, they change a question and assign a new GUID. Or, they insert a new question into the middle. I need to combine all the data sets, and attempt to preserve the natural order of the questions. Does that make a bit more sense?
In Section
Seekers of Perl Wisdom
|
|