Newbie question: Howto remove only first element from a list
Subject: Newbie question: Howto remove only first element from a list
From: Raymond Toy (RT/EUS)
Date: Fri, 25 Apr 2008 10:43:32 -0400
Alexey Beshenov wrote:
> On Friday 25 April 2008 18:31, Raymond Toy wrote:
>
>> (%i3) ? rest
>>
>> -- Function: rest (<expr>)
>> Returns <expr> with its first <n> elements removed if <n> is
>> positive and its last `- <n>' elements removed if <n> is negative.
>> If <n> is 1 it may be omitted. <expr> may be a list, matrix, or
>> other expression.
>>
>> I think it would be better to say something like
>>
>> -- Function: rest (<expr>[, <n>])
>>
>> to make it clear that there's an optional argument allowed.
>
> As for Maxima 5.14.0, it prints (as expected)
>
> -- Function: rest (<expr>, <n>)
> -- Function: rest (<expr>)
> Returns <expr> with its first <n> elements removed...
Interesting. I was running the CVS version. Maybe I have something
messed up.
Ray