|
[Date Index]
[Thread Index]
[Author Index]
Re: Question on Map or Apply
- To: mathgroup at smc.vnet.net
- Subject: [mg66382] Re: Question on Map or Apply
- From: "Scout" <Scout at nodomain.com>
- Date: Thu, 11 May 2006 02:15:22 -0400 (EDT)
- References: <e3sgbh$ln9$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
"LectorZ" <lectorz at mail.ru>
news:e3sgbh$ln9$1 at smc.vnet.net...
> Hi guys,
>
> I am trying to apply DaysBetween function to the following list:
>
> list={{{2006, 1, 16}, {2006,
> 3, 31}}, {{2006, 1, 24}, {2006, 3, 31}}, {{2005, 6, 17}, {2006,
> 3, 31}}}
>
> DaysBetween[list[[1, 1]], list[[1, 2]]] works well.
> What I need is to apply DaysBetween on the whole list conaining 3
> sublists and getting a new list as a result containing 3 numbers.
>
> Thanks,
>
> LZ
>
Hi,
you could try with this:
In[1]:= DaysBetween[#[[1]], #[[2]]] & /@ list
Out[1]= {74, 66, 287}
Regards,
~Scout~
Prev by Date:
Re: Question on Map or Apply
Next by Date:
Re: Mathematica Question
Previous by thread:
Re: Question on Map or Apply
Next by thread:
Re: Question on Map or Apply
|