Nepedia
Back to Discover
Independent Reader
🔢

Tuple

math Maturity 11-13 Next article →

Imagine you are making a list of items. In math, this list is called a tuple. A tuple is a set of things in a specific order. The order is very important. If you swap the items, it becomes a new list.

Tuples can hold many different things. They do not have to be just numbers. They can hold any math objects. We call these objects elements.

A tuple with one element is a singleton. A tuple with two elements is an ordered pair. A tuple with three elements is a triple. You can even have a tuple with zero elements. We call this the empty tuple.

Tuples are different from sets. In a set, the order does not matter. In a set, you cannot have the same item twice. But in a tuple, you can repeat items. For example, a tuple could be (1, 1).

Computer scientists use tuples too. They use them to store data in a specific way. Some computer programs use records instead. Records are like tuples, but the order does not matter. In those cases, you use labels to find your items.

187 words

Where will your curiosity go next?

Keep exploring at your chosen reading level.

More to explore

What is Nepedia?

A free, ad-free encyclopedia for children. Every article is written at five reading levels, so the same page works for a five-year-old and a fifteen-year-old — use the level switcher above to see this one change. No account needed to read.