On Mon, Jul 5, 2010 at 1:12 AM, sturlamolden <sturlamol...@yahoo.no> wrote:
> On 4 Jul, 10:03, Stefan Behnel <stefan...@behnel.de> wrote:
>
>> Sort of. One of the major differences is the "number" type, which is (by
>> default) a floating point type - there is no other type for numbers. The
>> main reason why Python is slow for arithmetic computations is its integer
>> type (int in Py3, int/long in Py2), which has arbitrary size and is an
>> immutable object. So it needs to be reallocated on each computation.
>
> That is why Lua got it right. A floating point type has a mantissa and
> can duck type an integer. MATLAB does the same.

I sincerly doubt it - where do take the information that matlab use
float to represent int ? It would not be able to represent the full
range of 64 bits integer for example.

David
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to