"William Stein" <[EMAIL PROTECTED]> writes:

> On 5/26/07, Robert Bradshaw <[EMAIL PROTECTED]> wrote:
>> On May 26, 2007, at 8:19 AM, Pablo De Napoli wrote:
>> > in standard iPython:
>> >
>> > In [1]: divmod(2,3)
>> > Out[1]: (0, 2)
>> >
>> > Would it better to use the standard name divmod for this operator [by
>> > defining a method __divmod__] (or other operators
>> > already defined in python) when possible?
>>
>> I think this would be a good idea. I don't know if there's any reason
>> we're not doing so yet...
>
> The reason is that none of use knew about __divmod__ for some reason...
> at least I didn't.  That's the only reason.

I seem to recall that Python's __divmod__ semantics are not
mathematically friendly, but maybe that is just C's semantics?
Perhaps someone who knows more should clarify?

Nick

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to