At the core of NumPy are arrays. Let’s formally define what an array is:
Given this broad definition of arrays, Python has two built-in types that resemble an array: the list and the tuple. We could use a list of lists or a dictionary of lists to store multiple lists, effectively creating multidimensional arrays. However, neither the list, the tuple, nor the dictionary is optimized for numerical purposes. They don’t even adhere to our definition that well since they can store values of different types. E.g., a list can contain a mixed collection of numbers, strings, and any other object type.
NumPy solves many of the Python shortcomings regarding numerical computation through arrays. Array creation and manipulation in NumPy are blazing fast and well-optimized. NumPy arrays are implemented in C, bypassing any speed limitations that Python might have.