Re: [Q] How to get rid of {} ???
- To: mathgroup@smc.vnet.net
- Subject: [mg10799] Re: [mg10685] [Q] How to get rid of {} ???
- From: Reinhold Kainhofer <reinhold.kainhofer@kfunigraz.ac.at>
- Date: Thu, 5 Feb 1998 00:58:43 -0500
- References: <199801300924.EAA15320@smc.vnet.net.>
Alessandro Rossi wrote:
> Hi everyone again...
> I'm just curious to ask if is it possible to get rid of the {} simbols
> in a plain list of this kind {a1, a2, a3, ..., an} when you want to use
> the ordered sequence of a1, a2, a3, ..., an as arguments for a
> function.
>
> If I have the following list:
> list={True, False, True}
>
> how can I computethe And Function of the three arguments of list:
>
> And[True, False, True]
>
> obviously
>
> And[list]
>
> doesn't work...
Try And[Sequence@@list]. This Replaces the head List of {True, False,
True}, which is internally represented by List[True, False, True] by
Sequence.
Hope this helps
Reinhold
____________________________________________________________________
Reinhold Kainhofer | e-mail: reinhold.kainhofer@kfunigraz.ac.at
Strassoldog. 4/3/17 | http://www.cryogen.com/rk 8010 Graz, Austria |
http://www.geocities.com/Athens/9145