take_while

one of the documented procedures in this installation of the ACS
Usage:
take_while   p   xs
What it does:
returns the longest initial segment of xs whose elements satisfy p
Defined in: /web/philip/tcl/ad-functional.tcl

Source code:


    set index 0    
    foreach x $xs {
	if { ![eval_unary $p $x] } { break }
	incr index
    }
    take $index $xs


philg@mit.edu