in reply to Date comparison Y2K problem

Most date-handling packages in CPAN have some understanding of two-digit years. What you do is to take the various components that make up a date (in your data), use them to create an object of a suitable date/time type, then use that in the sort-compare routine... comparing the date/time objects you've made, using the methods they provide for comparing themselves to things.

So you've handled the sorting process by means of a custom compare-function, and you've passed-off the date/time complexities to the object.

If you want something simpler, just write your own compare function and normalize the dates yourself: if the value's in the range x-y, add 1900 to it; else add 2000 to it. Good for a hundred years. (“Dig me up and I'll fix it then...”)