Kai Peters wrote:
> Hi All ~
> 
> I need to eliminate lines from a file that contain one or more words from a=
>  "negative" list.
> Below is some simplified code showing how I am currently doing this. Is=
>  there a faster/better way?
> 
> TIA
> Kai
> 
> 
> str:    "Romeo loves Juliet very much"
> neg:    [ "cheese" "bread" "wine" "very" ]
> strbl:  parse str none
> 
> if (length? strbl) + (length? neg) > length? union strbl neg [ print "kick=
>  out" ]
> 
> 

 >> difference strbl intersect strbl neg
== ["Romeo" "loves" "Juliet" "much"]
-- 
To unsubscribe from the list, just send an email to 
lists at rebol.com with unsubscribe as the subject.

Reply via email to