The module defines the following type:
-.. function:: array(typecode[, initializer])
+.. class:: array(typecode[, initializer])
- Return a new array whose items are restricted by *typecode*, and initialized
+ A new array whose items are restricted by *typecode*, and initialized
from the optional *initializer* value, which must be a list, string, or iterable
over elements of the appropriate type.
.. data:: ArrayType
- Obsolete alias for :func:`array`.
+ Obsolete alias for :class:`array`.
Array objects support the ordinary sequence operations of indexing, slicing,
concatenation, and multiplication. When using slice assignment, the assigned
The following data items and methods are also supported:
-
.. attribute:: array.typecode
The typecode character used to create the array.