module Ordered_Words { orderword=lambda ->{ buffer a as integer*30 =lambda a (s as string) -> { if len(s)*2>len(a) then buffer a as integer*len(s) return a, 0:=s if len(s)=1 then =true: exit for i=1 to len(s)-1 if a[i-1]>a[i] then break next i =true } }() max=2 res=stack document a$ load.doc a$, "unixdict.txt" k=doc.par(a$) i=0 m=Paragraph(a$, 0) if forward(a$, m) then while m i++ if i mod 20=1 then Print Over round(i/k*100,2);"%" : refresh word=paragraph$(a$, (m)) if orderword(word) then if max