Overview list & Array
Today we will see in our website kodlogs what is the difference between array and list in Python. Is this list exactly like array. What we have read in C ++ and Java actually means array and list in programming. The only difference is that in C ++ and c # and Java we can store the same data type. It can be in data integers and floats and strings. And in the list of Python. Anyone can store any data. That is, we can store anything in Python. If we have to do calculations in data science, then we have to use a numpy array in Python. Python has flexibility. I don't have to use a normal array.
Difference between List and Array
Greater flexibility, preferred for shorter Sequence of data item,consume larger memory for easy addition of elements. Different date type.
Less flexibility, preferred for longer sequence of data item.comparatively more compact in memory size.similar Datatype.
[2,'Kodlogs ',['k','t'] ]
For i in sample_array: