Probably a pointless question about using sort to search..

Peter M. Brigham pmbrig at gmail.com
Sat Dec 12 07:40:39 EST 2015


Just to be clear, it's not my function, it came from someone else on the list. It could easily be revised to handle the case of cr's within data chunks, though.

-- Peter

Peter M. Brigham
pmbrig at gmail.com
http://home.comcast.net/~pmbrig

On Dec 11, 2015, at 6:51 PM, Alex Tweedly wrote:

> 
> I haven't read everything in this thread, so I don't know if Peter's function handled this or not ...
> 
> 
> On 11/12/2015 23:32, Geoff Canyon wrote:
>> On Thu, Dec 10, 2015 at 12:47 PM, Peter Brigham <pmbrig at gmail.com> wrote:
>> 
>>> Someone on this list at some point posted an array sorting function that
>>> might be relevant here for some applications. See below.
>>> 
>> ​Why would anyone make a separate handler ​for this, and even more so, why
>> make it a function that takes a value by reference and then hands a value
>> back rather than a handler that changes the value in place?
>> 
>> But back to the first point, this function can be eliminated in three lines
>> of code:
>> 
>> combine someArray using cr
>> sort lines of someArray -- however you like
>> split someArray by cr
>> 
> Ummm ...
>   put "abc" & CR & "def" into somearray[1]
>   put "ghj" into somearray[2]
> and then try the above 3-line code snippet.
> 
> -- Alex.
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list