operator ** and pow function behaves differently

anupam anupamk at mindspringdot.com
Sun Jul 9 17:38:58 EDT 2000


hi all,

i am a newbie in the python world. from my understanding so far,
i thought that ** operator and pow functions are symmetrical. but
apparently i was wrong, e.g. -1**0 yields -1 but pow(-1,0) yields
1 (which is correct).

any pointers on why this is ?
please be gentle !!!

thanks

anupam







More information about the Python-list mailing list