Talk:Horner's rule for polynomial evaluation: Difference between revisions

(→‎J language and p.: Does p. use Horner's?)
 
(One intermediate revision by one other user not shown)
Line 6:
==J language and p.==
Just wondered, does p. use Horner's rule? --[[User:Paddy3118|Paddy3118]] 03:11, 1 April 2010 (UTC)
 
: Actually, #. (which represents the core of Horner's approach and is incredibly useful) existed in the language spec long before p. and p. was added for convenience and to support a few other related polynomial mechanisms. (So, it is almost certain that p. uses Horner's rule.) --[[User:Rdm|Rdm]] 15:06, 12 August 2010 (UTC)
 
== C++ solution: Error ==
 
I think there's a bug in the C++ solution (the original one, not the more idiomatic one I just added): It seems that it decrements an iterator to the first element of the vector, which is undefined behaviour (and may trigger a run time error on certain implementations). --[[User:Ce|Ce]] 12:42, 12 August 2010 (UTC)
6,951

edits