Simon Cozens wrote: > With all due respect, that's not been my experience. Even beginners know > how to do things like "length", by far the most common case for the ST. You must be kidding. Sorting a list of strings by length is more common that, say, sorting them numerically by some embedded number? I don't think so. Besides, simply sorting strings by length doesn't require ST. The ST applies when you want to sort by one or more embedded "fields". So, sorting by length of an embedded field is the most common case? I can honestly say that I have never done this, seen it, recommended it, or seen it recommended (though I admit it must come up from time to time): map { $_->[0] } sort { $a->[1] <=> $b->[1] } map { my($s) = /X(.*?)Y/; [ $_, length($s) ] } @items -- John Porter Useless use of time in void context.
- Re: Schwartzian Transform Nick Ing-Simmons
- Re: Schwartzian Transform Adam Turoff
- Re: Schwartzian Transform Dan Sugalski
- Re: Schwartzian Transform James Mastros
- Re: Schwartzian Transform John Porter
- Re: Schwartzian Transform Uri Guttman
- Re: Schwartzian Transform Simon Cozens
- Re: Schwartzian Transform indigo
- Re: Schwartzian Transform Uri Guttman
- Re: Schwartzian Transform Simon Cozens
- Re: Schwartzian Transform John Porter
- Re: Schwartzian Transform Jarkko Hietaniemi
- Re: Schwartzian Transform John Porter
- Re: Schwartzian Transform Jarkko Hietaniemi
- Re: Schwartzian Transform Simon Cozens
- Re: Schwartzian Transform John Porter
- Re: Schwartzian Transform Trond Michelsen
- Re: Schwartzian Transform Dan Sugalski
- Re: Schwartzian Transform Dan Sugalski
- Re: Schwartzian Transform John Porter
- Re: Schwartzian Transform Dan Sugalski