repeat with each woord currentWord in myString

Mark Brownell gizmotron at earthlink.net
Sat Mar 20 17:12:46 EST 2004


On Saturday, March 20, 2004, at 01:14  PM, A.C.T. wrote:

> put 1 into counter
> repeat for each word someWord in someVariable
> put someWord into wordarray[counter]
> increment counter by 1 # don't know if Transcript can do this,
> # the proper way would be to say "counter++", naturally
> end repeat

Another way to get an array may be to use the split command:

-- split someVariable by space

This split command will turn someVariable into a numerical keyed array.

It's worth speed testing. I used it to optimize rev_blowfishCBC.rev.
There might be some conflict issues with return characters & line feeds 
using this however.

Mark Brownell



More information about the use-livecode mailing list