04-17-2019, 02:48 AM
not completely sure on what your asking but try this
out
str s=
;c:\program files\myexe1.exe
;c:\program files\myexe2.exe
;c:\program files\myexe3.exe
;c:\program files\myexe4.exe
;c:\program files\myexe5.exe
;c:\program files\myexe6.exe
;c:\program files\myexe7.exe
;c:\program files\myexe8.exe
;c:\program files\myexe9.exe
;c:\program files\anotherone.exe
str sw=
;myexe
;mystuff
;anotherone
;somethingelse
sub.Included_Words s sw _s
,out _s
#sub Included_Words
function str&Word_list str&Included_Words str&outlist
ARRAY(str) am au AM AU
foreach _s Included_Words
,if(find(Word_list _s 0 1)<0) au[]=_s
,else am[]=_s
foreach _s Word_list
,for(_i 0 am.len)
,,if(find(_s am[_i] 0 1)>=0) break
,if(_i<am.len)
,,AM[]=_s;
,,if(numlines(outlist) <5)
,,,outlist.addline(_s 1)
,else
,,AU[]=_s