View Single Post
  #5 (permalink)  
Old 03-28-08, 04:29 AM
UnrealEd's Avatar
UnrealEd UnrealEd is offline
Community Liaison
 
Join Date: May 2005
Location: Antwerp, Belgium
Posts: 3,165
Thanks: 4
Thanked 25 Times in 25 Posts
ow, sorry, I thought the string was "cancer lung". Well then!

This should do:
Code:
(([a-zA-Z]+)(?:\sof)?\s(?=lung))
this will result in ('cancer of lung', 'cancer') or ('something lung', 'something')
__________________
"Good judgement comes from experience, and experience comes from bad judgement." - Fred Brooks

Reply With Quote