This is one possible solution, however it's time complexity is O(N^2)
and can be unacceptable for producing intermediate results from an
operation over a list of N items.
A recursive solution (such as using the FXSL scanl()
template/function) can have a O(N) complexity.
--
Cheers,
Dimitre Novatchev
---------------------------------------
Truly great madness cannot be achieved without significant intelligence.
On 7/11/06, Andrew Franz <afranz0(_at_)optushome(_dot_)com(_dot_)au> wrote:
How about just sum the predecessor axis (with selection)?
(Apologies if someone already suggested this - I missed the start of the
thread)
Steve wrote:
> Any other takers?
>
> I'd have to have to resort to some hack if I can do this with XSL.
>
> -S
>
> On 7/10/06, Steve <subsume(_at_)gmail(_dot_)com> wrote:
>
>> Problem: I need to make a table of the output required of 4 factories
>> next month.
>>
>> Widgets Gadgets
>> Factory A 2
>> Factory B 3
>> Factory C 4
>> Factory D 1
>>
>> Widget quota = 5
>> Gadget quota = 5
>>
>
> --~------------------------------------------------------------------
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
> To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
> or e-mail:
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
> --~--
>
>
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--