in reply to Sort Says "not numeric" then sorts numeric anyway?

Thanks everyone. I'm kicking myself about that regex thing. I think I was kind of halfway there, but yeah how dumb not to realise it was staying sorted, not being sorted.

I'm guessing that what my silly regex-sort did was return a "1" or a "true" for both sides of the comparison -- "yes, there are digits at the start", and so everying was "is-one-bigger-or-smaller-than-one" and nothing happened?
--

“Every bit of code is either naturally related to the problem at hand, or else it's an accidental side effect of the fact that you happened to solve the problem using a digital computer.”
M-J D
  • Comment on Re: Sort Says "not numeric" then sorts numeric anyway?