[issue24526] Exponent function bug

2015-06-29 Thread bhaskar

Changes by bhaskar b.bhaskar.n...@gmail.com:


Added file: http://bugs.python.org/file39830/pythonabc.png

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue24526
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24526] Exponent function bug

2015-06-29 Thread bhaskar

New submission from bhaskar:

the value of a -ve number when raised by a power of even number always results 
in a +ve number. I tried it with -1**10 , -1**2, -9**4

these all are resulting in -ve numbers which is mathematically incorrect.

ps. the same example is in the attachment

--
components: IDLE
files: pythonabc.png
messages: 245928
nosy: bhaskar
priority: normal
severity: normal
status: open
title: Exponent function bug
type: compile error
versions: Python 3.6
Added file: http://bugs.python.org/file39829/pythonabc.png

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue24526
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24526] Exponent function bug

2015-06-29 Thread R. David Murray

R. David Murray added the comment:

This bit of python's precedence rules often catches people by surprise.  ** 
binds tighter than -, so what python is evaluating is -(1**10).

--
nosy: +r.david.murray
resolution:  - not a bug
stage:  - resolved
status: open - closed
type: compile error - behavior

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue24526
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com