Python arrays and lists: In Python have the same way of storing data. But, arrays can hold only a single data type elements whereas lists can hold any data type elements.
import array as arr
array(‘i’, [1, 2, 3, 4]) [1, ‘abc’, 1.2]
If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.