New submission from Marco Sulla <launchpad....@marco.sulla.e4ward.com>:

(venv_3_9) marco@buzz:~/sources/python-frozendict$ python
Python 3.9.0a0 (heads/master-dirty:d8ca2354ed, Oct 30 2019, 20:25:01) 
[GCC 9.2.1 20190909] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> a = 1E9
>>> type(a)
<class 'float'>

IMHO if the exponent is positive, and the  "base number" (1 in the example) is 
an integer, the result should be an integer.

Optionally, also if the "base number" has a number of decimal places <= the 
exponent, the result should be an integer. Example:

1.25E2 == 125

If the user wants a float, it can write

1.2500E2 == 125.0

----------
components: Interpreter Core
messages: 362918
nosy: Marco Sulla
priority: normal
severity: normal
status: open
title: Exponential notation should return an int if it can
type: enhancement
versions: Python 3.9

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

Reply via email to