On Fri, Dec 01, 2006 at 10:18:41PM -0500, sen1 at math.msu.edu wrote:
> Hello,
> The command
>
> sublist(L,evenp)
> extracts the even entries in the list L.
>
> Is there a simple command to extract the non-zero elements in a list?
>
maxima inherited "anonymous functions" from its lisp heritage. the
lambda function allows you to define simple useful functions
on-the-spot so to speak.
for example
(%i1) sublist([1,2,0,3-3],lambda([x],x #0));
(%o1) [1, 2]
--
Daniel Lakeland
dlakelan at street-artists.org
http://www.street-artists.org/~dlakelan