Jump to content

Sum multiples of 3 and 5: Difference between revisions

Line 1,980:
 
=={{header|Maxima}}==
{{incorrect|Maxima|output should be 233168}}
As the wrong result matched with powershell, I suspect there is a missing -1 here somewhere.
<lang Maxima>sumi(n, incr):= block([kmax: quotient(n, incr)],
''(ev(sum(incr*k, k, 1, kmax), simpsum)));
7,795

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.