Talking about "arrays" and "lists" as abstract data types without referring to any particular implementation can be a bit confusing, because those two are not very well defined.

The two Wikipedia pages List (abstract data type) and Array data type make this ambiguity somewhat evident, with uncertain statements such as "Implementation of the list data structure may provide some of the following operations:".

In many languages, there is a type called list and a type called array and they have some better defined meaning.

Here is a very general summary.

Lists:

  • a list is linear, it is an ordered sequence of elements;
  • you can access the first element of a list;
  • you can add a new element to a list;
  • you can access all elements of the list one after the other, starting from the first element. That last operation is done either with "arbitrary access" (accessing elements as l[0], l[1], l[2], etc.) or with two operations called "head" and "tail", where head(l) returns the first element of l and tail(l) returns the sublist obtained by discarding the first element.

In my mind, a list of four elements looks like this:

-> 3 -> 7 -> 12 -> 9

Arrays:

  • an array provides "arbitrary access" using indices (accessing elements as a[something]);
  • sometimes the index is restricted to integers between 0 and the length of the array; sometimes the index can be anything and everything;
  • you can easily modify elements that you access, but you cannot necessarily add new elements.

An array which allows anything to be used as index is usually called a map or a dict in most languages, where array refers strictly to linear structures indexed by integers; but in a few languages, for instance PHP, it is still called an array.

In my mind, an array of four elements looks like this:

+--+--+--+--+
| 0| 1| 2| 3|
+--+--+--+--+
| 3| 7|12| 9|
+--+--+--+--+

Tuples:

  • a linear, ordered sequence of elements;
  • usually can contain elements of different types, whereas in most languages, all the elements in a list must have the same type;
  • usually cannot add/remove elements
  • in strongly-typed languages, such as Haskell or OCaml, the type of a tuple is given by its length and the enumeration of the types used in it, for instance the tuple (3, 7, 12.0, "9") has type (int, int, float, string), and a function returning a specific type of tuple cannot suddenly return a tuple of a different type.

Tuples in strongly-typed languages are sometimes called "product types" by analogy with the Cartesian product in mathematics, and are very close to struct in C. Tuples in weakly-typed languages are very close to lists.

Answer from Stef on Stack Overflow
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ python โ€บ python-list-vs-array-vs-tuple
Python List VS Array VS Tuple - GeeksforGeeks
July 15, 2025 - In Python, List, Array and Tuple are data structures for storing multiple elements. Lists are dynamic and hold mixed types, Arrays are optimized for numerical data with the same type and Tuples are immutable, ideal for fixed collections.
๐ŸŒ
Reddit
reddit.com โ€บ r/learnprogramming โ€บ what is the difference between a tuple, list, and array? when and why to use each one.
r/learnprogramming on Reddit: What is the difference between a Tuple, List, and Array? When and why to use each one.
August 17, 2015 -

I've read through the wikis on each and some stack overflow Q&A but km still not getting a solid difference.

To be quite honest I've only ever used arrays in my programs.

From my understanding, An array uses keys to point to memory addresses for the respective values. A list is sequential. Both an array and list are homogeneous but a tuple is heterogeneous. But thats all I've really learned about each.

Why and when would I use a tuple? I don't see a need for heterogeneous data to be gathered, it seems to me that it would just cause confusion in my code.

Any help would be greatly appreciated.

Top answer
1 of 4
3
Array: contiguous in memory (so each element is one after the other). fixed sized. very space efficient. very efficient to iterate over and access random elements. not efficient to insert something new in the middle of it, or to delete something. dynamic arrays (vectors, arraylist, etc) can be efficiently resized, and are the preferred data structure for lists unless you have a reason not to use them. (Linked) list: not continuous in memory. each node of the list contains data and a pointer/reference to the next element (and maybe a pointer to the previous). fairly efficient to iterate over. inefficient to access a random element, but efficient to access to first (and maybe last) element, efficient to add an element after (and maybe before) another, or remove an element. very efficient to merge and splice. tuple: completely different. tuples (or product types) do not represent a list of data. They are an object with a fixed dimension and each coordinate contains a particular type of data (in linked lists and arrays data is homogenous; in tuples it's often not).
2 of 4
3
Well, let's start with an array. An array is a relatively basic sort of data structure, and is generally considered to have the following characteristics: It has a fixed size It's made up of a contiguous chunk of memory As a consequence, accessing an arbitrary element inside of an array is an O(1) operation, but resizing that array or adding a new element is an O(n) operation since you need to copy every value over to a new array. A list is similar to an array, but has a variable size, and does not necessarily need to be made up of a single continuous chunk of memory. While this does make lists more useful in general then arrays, you do incur a slight performance penalty due to the overhead needed to have those nicer characteristics. I should also note that a List is not a specific kind of data structure. Rather, it's an abstract data type -- a description of what a data structure should behave like. There are several different kinds of list implementation you can try using, but the two most common ones are an array list and a linked list. An array list is basically a lightweight wrapper around an array. When the internal array is full, the array list class will automatically allocate and use a bigger array. A linked list works by chaining together a sequence of "node" objects, each of which contains a value, and points to the next and previous elements in the list. (The benefit of this data structure is that appending new values is an O(1) operation). Tuples are a little different then both arrays and lists. Arrays and lists are intended, as you said, to hold a sequence of homogenous values, whereas a tuple isn't necessarily intended to be iterated over and can hold heterogeneous values. (Tuples also are typically immutable -- you cannot change their values or add/remove new elements. That makes them more lightweight then lists). And I suppose while tuples can potentially be confusing, especially if you overdo them, they're actually really expressive and useful when you're working in a language that has first-class support for them. For example, take Python. Let's say that I want to take two distinct lists, combine each element against the next one, and iterate over them. For example: >>> names = ['Alice', 'Bob', 'Charlie', 'Danielle'] >>> ages = [8, 2, 5, 7] >>> joined = zip(names, ages) >>> print joined [('Alice', 8), ('Bob', 2), ('Charlie', 5), ('Danielle', 7)] >>> for name, age in joined: ... print(age, name) ... 8 Alice 2 Bob 5 Charlie 7 Danielle Here, I'm taking advantage of several features. I'm using the zip function to bundle together each element in both lists, producing a list of tuples. While I suppose the zip function could return a list of custom Pair objects, returning a list of tuples makes the function nicely consistent with the rest of the language. Getting key-pair values in a map returns a list of tuples, the enumerate function returns a list of tuples, etc... I can use the same syntax with all of them. I'm using tuple unpacking to automatically destructure and get every element in the tuple when I'm looping. This way, I don't have to manually pick an index to grab an element out of a tuple. I unpack it, and move on. In a nutshell, tuples free you from having to make small, custom, one-off classes whenever you want to return or work with a small bundle of data. It's a feature you have to use responsibly, but if you do, it can help make your code much less verbose.
๐ŸŒ
DevOpsSchool.com
devopsschool.com โ€บ home โ€บ python tutorials: difference between list & array & tuple & set & dict
Python Tutorials: Difference between List & Array & Tuple & Set & Dict - DevOpsSchool.com
December 23, 2022 - Sequence means that the elements are ordered, and indexed to start at index 0. However, unlike lists, arrays can only contains items of the same data type such as Ints, Floats, or Characters.
๐ŸŒ
FreelancingGig
freelancinggig.com โ€บ home โ€บ python list vs array vs tuple โ€“ understanding the differences
Python List vs Array vs Tuple - Understanding the Differences - Developers, Designers & Freelancers - FreelancingGig
May 17, 2018 - Out of all data structures, a tuple is considered to be the fastest and they consume the least amount of memory. While array and list are mutable which means you can change their data value and modify their structures, a tuple is immutable.
Top answer
1 of 2
5

Talking about "arrays" and "lists" as abstract data types without referring to any particular implementation can be a bit confusing, because those two are not very well defined.

The two Wikipedia pages List (abstract data type) and Array data type make this ambiguity somewhat evident, with uncertain statements such as "Implementation of the list data structure may provide some of the following operations:".

In many languages, there is a type called list and a type called array and they have some better defined meaning.

Here is a very general summary.

Lists:

  • a list is linear, it is an ordered sequence of elements;
  • you can access the first element of a list;
  • you can add a new element to a list;
  • you can access all elements of the list one after the other, starting from the first element. That last operation is done either with "arbitrary access" (accessing elements as l[0], l[1], l[2], etc.) or with two operations called "head" and "tail", where head(l) returns the first element of l and tail(l) returns the sublist obtained by discarding the first element.

In my mind, a list of four elements looks like this:

-> 3 -> 7 -> 12 -> 9

Arrays:

  • an array provides "arbitrary access" using indices (accessing elements as a[something]);
  • sometimes the index is restricted to integers between 0 and the length of the array; sometimes the index can be anything and everything;
  • you can easily modify elements that you access, but you cannot necessarily add new elements.

An array which allows anything to be used as index is usually called a map or a dict in most languages, where array refers strictly to linear structures indexed by integers; but in a few languages, for instance PHP, it is still called an array.

In my mind, an array of four elements looks like this:

+--+--+--+--+
| 0| 1| 2| 3|
+--+--+--+--+
| 3| 7|12| 9|
+--+--+--+--+

Tuples:

  • a linear, ordered sequence of elements;
  • usually can contain elements of different types, whereas in most languages, all the elements in a list must have the same type;
  • usually cannot add/remove elements
  • in strongly-typed languages, such as Haskell or OCaml, the type of a tuple is given by its length and the enumeration of the types used in it, for instance the tuple (3, 7, 12.0, "9") has type (int, int, float, string), and a function returning a specific type of tuple cannot suddenly return a tuple of a different type.

Tuples in strongly-typed languages are sometimes called "product types" by analogy with the Cartesian product in mathematics, and are very close to struct in C. Tuples in weakly-typed languages are very close to lists.

2 of 2
0

Yeah, you are right.

Array can be created with fixed size and it is not possible to add items if array is full.

List is dynamic array and it can add items how many you want. Under the hood array is used in List in some languages, e.g. in C#. When new item is added and an array is full, then new array will be created with doubled size.

You can see the implementation of List<T> in C#

๐ŸŒ
Real Python
realpython.com โ€บ python-lists-tuples
Lists vs Tuples in Python โ€“ Real Python
January 26, 2025 - Python lists and tuples are sequence data types that store ordered collections of items. While lists are mutable and ideal for dynamic, homogeneous data, tuples are immutable, making them suitable for fixed, heterogeneous data. Read on to compare ...
๐ŸŒ
Quora
quora.com โ€บ What-are-the-practical-differences-between-a-list-a-tuple-and-an-array-in-Python
What are the practical differences between a list, a tuple, and an array in Python? - Quora
Answer (1 of 5): The practical difference between a Python List, Tuple and Array? Lists in Python are your go-to un-keyed mutable collection for just about everything. (you use dicts for keyed collections). a dict where the key is a tuple of some kind e.g. (name, account number ) and the value i...
๐ŸŒ
OnlineGDB
question.onlinegdb.com โ€บ 14235 โ€บ whats-the-difference-between-arrays-and-tuples-in-python
What's the difference between arrays and tuples in python? - OnlineGDB Q&A
I have been learning python as my 2nd programming language after javascript (Stopped learning it). When ... )'s. Just please, tell me the difference.
Find elsewhere
๐ŸŒ
Medium
medium.com โ€บ @leroyleowdev โ€บ choosing-between-tuples-arrays-and-lists-performance-requirement-considerations-d01637c05aa5
Choosing Between Tuples, Arrays, and Lists: Performance & Requirement Considerations | by Leroy Leow | Medium
July 21, 2024 - Homogeneous: Like arrays, lists also store elements of the same type. However, because they are dynamic, they can be more versatile in scenarios where the collection size varies. Use Case: Lists are preferred when you need a collection that can change size, such as storing user input or processing a variable number of items. Fixed Size and Heterogeneous: Tuples can contain a fixed number of elements of different types.
๐ŸŒ
Reddit
reddit.com โ€บ r/programminglanguages โ€บ question comparing tuple & array
r/ProgrammingLanguages on Reddit: Question Comparing Tuple & Array
November 23, 2023 -

I'd like to hear others' thoughts on this. I've been looking into the trade-offs between differing implementations of data structures. One I'm curious about but it's hard to find quality information about is Tuple vs Array.

Most searches will find discussions about Tuple vs List (Deque/Queue/Linked memory implementations). And the trade offs are near identical to Array vs List (as expected).

  • It's frequently touted that Tuples are quick to create / destroy. But typed Arrays should be too, they know the byte size for all the elements at the start. I'd expect both a typed Tuple or Array to be very quick to create / destroy.

If a language had to support one or the other, which is more preferable?

Factors to Consider:

  • Either would be fixed size and continuous memory.

  • The Tuple would be immutable, while the Array would only be mutable.

  • The Array may or may not be atomic.

  • Assume the language follows your preferred paradigms ( supports concurrent or parallel programming, etc. ).

  • Assume that the only other language supported data structures would be fundamental implementations of a DE_Queue, Struct (K-V), and a HashTable.

๐ŸŒ
Python documentation
docs.python.org โ€บ 3 โ€บ tutorial โ€บ datastructures.html
5. Data Structures โ€” Python 3.14.3 documentation
Tuples are immutable, and usually ... attribute in the case of namedtuples). Lists are mutable, and their elements are usually homogeneous and are accessed by iterating over the list....
๐ŸŒ
Quora
quora.com โ€บ What-is-the-difference-between-a-list-tuple-and-array-in-Python-What-are-their-respective-use-cases
What is the difference between a list, tuple, and array in Python? What are their respective use cases? - Quora
Answer: Array are fixed by definition. A list is dynamic and tuples are unmutable. The point with tuples is that function can return tuples that is, multiple values. A use of tuples is a drop down list on a web app.
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ python โ€บ differences-and-applications-of-list-tuple-set-and-dictionary-in-python
Differences and Applications of List, Tuple, Set and Dictionary in Python - GeeksforGeeks
October 3, 2025 - Lists can be used to manipulate ... using split() and convert each word to uppercase using a loop. A Tuple is a collection of Python objects separated by commas....
๐ŸŒ
Built In
builtin.com โ€บ software-engineering-perspectives โ€บ python-tuples-vs-lists
Python Tuples vs. Lists | Built In
Tuples and lists are Python data structures used to store a collection of items in one variable, though tuples are immutable and lists are mutable. Hereโ€™s how and when to use Python tuples vs. lists, including easy-to-understand examples for ...
๐ŸŒ
LearnPython.com
learnpython.com โ€บ blog โ€บ python-lists-tuples-sets
Python Lists, Tuples, and Sets: Whatโ€™s the Difference? | LearnPython.com
Learn how Python lists are different from arrays in this article. A Python tuple is another built-in data structure that can hold a collection of elements. Tuples are technically very similar to lists.
Top answer
1 of 7
875

Tuples are fixed size in nature whereas lists are dynamic.
In other words, a tuple is immutable whereas a list is mutable.

  1. You can't add elements to a tuple. Tuples have no append or extend method.
  2. You can't remove elements from a tuple. Tuples have no remove or pop method.
  3. You can find elements in a tuple, since this doesnโ€™t change the tuple.
  4. You can also use the in operator to check if an element exists in the tuple.

  • Tuples are faster than lists. If you're defining a constant set of values and all you're ever going to do with it is iterate through it, use a tuple instead of a list.

  • It makes your code safer if you โ€œwrite-protectโ€ data that does not need to be changed. Using a tuple instead of a list is like having an implied assert statement that this data is constant, and that special thought (and a specific function) is required to override that.

  • Some tuples can be used as dictionary keys (specifically, tuples that contain immutable values like strings, numbers, and other tuples). Lists can never be used as dictionary keys, because lists are mutable.

Source: Dive into Python 3

2 of 7
273

There's a strong culture of tuples being for heterogeneous collections, similar to what you'd use structs for in C, and lists being for homogeneous collections, similar to what you'd use arrays for. But I've never quite squared this with the mutability issue mentioned in the other answers. Mutability has teeth to it (you actually can't change a tuple), while homogeneity is not enforced, and so seems to be a much less interesting distinction.

๐ŸŒ
Simplilearn
simplilearn.com โ€บ home โ€บ resources โ€บ software development โ€บ differences between list and tuple in python
Differences Between List and Tuple in Python
December 21, 2025 - Understand the key differences between lists and tuples in Python. Learn about mutability, performance, and use cases for each data structure.
Address ย  5851 Legacy Circle, 6th Floor, Plano, TX 75024 United States
๐ŸŒ
LearnPython.com
learnpython.com โ€บ blog โ€บ python-array-vs-list
Array vs. List in Python โ€“ What's the Difference? | LearnPython.com
So what's the difference between an array and a list in Python? In this article, we'll explain in detail when to use a Python array vs. a list. Python has lots of different data structures with different features and functions. Its built-in data structures include lists, tuples, sets, and ...
๐ŸŒ
Hyperskill
hyperskill.org โ€บ learn โ€บ step โ€บ 38095
Hyperskill
Hyperskill is an educational platform for learning programming and software development through project-based courses, that helps you secure a job in tech. Master Python, Java, Kotlin, and more with real-world coding challenges.
๐ŸŒ
Quora
quora.com โ€บ What-are-the-differences-between-a-string-list-tuple-and-an-array-in-Python
What are the differences between a string, list, tuple, and an array in Python? - Quora
Answer: A list can hold any mix of items. So can a tuple. You can append to a list of delete an element, because lists are mutable. You can't do either of those to a tuple because tuples are immutable. However, you can make a new tuple which mitigates that. Arrays are new in Python, they hold onl...