I was wandering around in stack overflow for questions when i saw that some people used arrays and others used lists and i was wondering what is the difference between list and arrays.
The over simplified answer is that arrays contain data in contiguous space in memory and lists generally store their information in non-contiguous space. In an array you know what the next data element is by moving down to the next element like moving to the house next door on a street. It's the physical displacement across a standard size memory boundary that lets you find the next element.
In an "list" each element in the list keeps a "pointer" to the location of the next element in the list. So in an array you can jump to the 5th element just as you can walk straight to the fifth house on a street. In a list you'd have to knock on each house's door and ask inside what the address of the next house in the group (i.e. list) is. That next house could be anywhere in the city.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With