[Tutor] dynamic arrays?
steve at pearwood.info
Mon Sep 27 19:49:50 CEST 2010
On Tue, 28 Sep 2010 01:45:56 am Brian Jones wrote:
> A python list and a python array are one and the same to my
Close, but not quite.
Python has an array type. It is almost identical to lists, except the
type of data it will hold is constrained to a specific type:
>>> import array
>>> a = array.array('i')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: an integer is required
More information about the Tutor