Re: having trouble understanding the built-in Perl sort with regards to mixed numbers and strings

2016-06-20 Thread Kenneth Wolcott
On Mon, Jun 20, 2016 at 10:40 AM, Shlomi Fish wrote: > Hi Chris, > > On Mon, 20 Jun 2016 11:28:57 -0600 > Chris Fedde wrote: > >> Kenneth, >> >> Below the cut is my example implementation as I understand your >> requirements. >> Note that the "compare" routine uses $a and $b which are "special" t

Re: having trouble understanding the built-in Perl sort with regards to mixed numbers and strings

2016-06-20 Thread Shlomi Fish
Hi Chris, On Mon, 20 Jun 2016 11:28:57 -0600 Chris Fedde wrote: > Kenneth, > > Below the cut is my example implementation as I understand your > requirements. > Note that the "compare" routine uses $a and $b which are "special" to perl > sort routines. > Also the compare routine is written for

Re: having trouble understanding the built-in Perl sort with regards to mixed numbers and strings

2016-06-20 Thread Chris Fedde
Kenneth, Below the cut is my example implementation as I understand your requirements. Note that the "compare" routine uses $a and $b which are "special" to perl sort routines. Also the compare routine is written for obviousness rather than for brevity or elegance. The return from compare illustr