Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

getting 64 bit integer in python

So I am thinking of writing a bitboard in python or lisp. But I don't know how to ensure I would get a 64 bit integer in python. I have been reading documentation and found that mpz library returns a unsigned 32 bit integer. Is this true? If not what should I do?

like image 682
Mark Avatar asked Dec 30 '11 06:12

Mark


1 Answers

Python 2 has two integer types: int, which is a signed integer whose size equals your machine's word size (but is always at least 32 bits), and long, which is unlimited in size.

Python 3 has only one integer type, which is called int but is equivalent to a Python 2 long.

like image 181
Taymon Avatar answered Oct 28 '22 02:10

Taymon