Regular Expression question

Devin Asay devin_asay at byu.edu
Wed Aug 9 15:27:38 EDT 2006


Having been caught by things like this before, I would suggest a  
small modification to Bob's script:

On Aug 9, 2006, at 12:21 PM, Robert Sneidar wrote:

>
> put <yourdatahere> into moldlist
> put "" into mnewlist
>
> repeat for each line theLine of moldlist
> if line theLine is among the lines of mnewlist then
		    ^^^^^^^^^^^^^^^^^^^
>   next repeat
> else
>   put line theLine of moldlist & return after mnewlist
> end repeat

This will work if the numbers in your list go to > 9 and they are not  
in numeric order. For instance,

10
10
10
2
2
1
1
1

If you just check "is in" the script will skip '1', since 1 is in 10.  
The 'among the lines of' forces the comparison to only consider whole  
line matches.

Devin

Devin Asay
Humanities Technology and Research Support Center
Brigham Young University




More information about the use-livecode mailing list