Talk:Greatest subsequential sum: Difference between revisions

added a header for the first topic so the table-of-contents shows up before the topic headers.
(→‎Erroneous Examples: Summation is properly defined for this task.)
(added a header for the first topic so the table-of-contents shows up before the topic headers.)
 
(5 intermediate revisions by 5 users not shown)
Line 1:
== what is the task?==
Currently this contains some ruby code, and no clear description of exactly what the task is. Please clarify the exact goal so others can provide implementations for the languages they use. --- [[User:crc|crc]] 2007-06-21
 
Line 20 ⟶ 21:
 
:It is wholly sensible to specify summation such that zero is the result of summation of a list of no elements. While this is not derivable from the qualities of addition, it may be established by definition. The value of avoiding exceptional conditions is very high. To have summation defined for all nonnegative integers allows many things to be specified simply that would otherwise involve messy special-case handling. One important result is notational clarity. For the unusual situations where summation should be rejected for lists shorter than two elements, input qualification testing will suffice. --[[User:TBH|TBH]] 06:15, 4 January 2008 (PST)
 
==Some bugs==
The second Python version (and probably other versions, I have fixed the D version) have bugs, try:
[-1, 1, 2, -5, -6]
 
:I've fixed the bug in Python version [functions maxsumseq() and maxsumit()] - [[User:A|a__]] 17:17, 28 March 2011 (UTC)
 
==Open question==
Take n random sequences, each of 1000 random numbers in [-1000 .. 1000].
Take the mean M<sub>n</sub> of their best score ( sum of values of max sub-sequence / n). Is there a limit for M<sub>n</sub> when n → ∞ ? Experiments show something around 22000, but a formal proof will be great !
--[[User:G.Brougnard|G.Brougnard]] ([[User talk:G.Brougnard|talk]]) 17:55, 20 September 2015 (UTC)