New submission from Neil Webber <n...@neilwebber.com>:

The math module documentation says:

   Except when explicitly noted otherwise, all return values are floats.

But this code returns an integer:

   from math import prod; prod((1,2,3))

Doc should "explicitly note otherwise" here, I imagine. The issue being wanting 
to know that the result on all-integer input will be an exact (integer) value 
not a floating value.

----------
assignee: docs@python
components: Documentation
messages: 413741
nosy: docs@python, neilwebber
priority: normal
severity: normal
status: open
title: math.prod can return integers (contradicts doc)
type: behavior

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue46828>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to