DOCUMENTATION CENTER SEARCH
Mathematica
>
Functional Iteration
>
Built-in
Mathematica
Symbol
Applying Functions Repeatedly
Tutorials »
|
LengthWhile
NestWhile
While
Take
Select
See Also »
|
Conditionals
Elements of Lists
Functional Iteration
Functional Programming
New in 6.0: Core Language
New in 6.0: List Manipulation
More About »
TakeWhile
TakeWhile
[
list
,
crit
]
gives elements
e
i
from the beginning of
list
, continuing so long as
crit
[
e
i
]
is
True
.
EXAMPLES
CLOSE ALL
Basic Examples
(2)
Take elements while they are all even:
In[1]:=
Out[1]=
Use a pure function to take elements while they are all below 10:
In[1]:=
Out[1]=
Scope
(1)
Applications
(1)
Properties & Relations
(3)
Possible Issues
(1)
SEE ALSO
LengthWhile
NestWhile
While
Take
Select
TUTORIALS
Applying Functions Repeatedly
MORE ABOUT
Conditionals
Elements of Lists
Functional Iteration
Functional Programming
New in 6.0: Core Language
New in 6.0: List Manipulation
New in 6
© 2008 Wolfram Research, Inc.