How do you make an array in Python?
Answer / chaitanya
The array module contains methods for creating arrays of fixed types with homogeneous data types. Arrays are slower then list.
Array of characters, integers, floating point numbers can be created using array module.
array(typecode[, intializer])
Returns a new array whose items are constrained by typecode, and initialized from the optional initialized value. Where the typecode can be for instance ‘c’ for character value, ‘d’ for double, ‘f’ for float.
| Is This Answer Correct ? | 0 Yes | 0 No |
How will you share global variables across modules?
Is javascript easier than python?
How do you find the type and identification number of an object in python?
Do you know what is numpy and how is it better than a list in python?
How will you print the contents of a file?
What are the disadvantages of the Python programming language?
What is break in python?
What are negative indexes?
Do python functions need return?
What is egg and wheel in python?
Understanding python super() with __init__() methods?
How do you sort in python 3?