What is a tuple

by Arnold Burian

Check out What is a tuple by JR. Here is an excerpt:

A tuple is a immutable heterogenous data structure while Lists are homogenous sequences. Tuples have structure. Lists have order.

For example say we wanted to save notes in a book on a specific page an line number. We could define that data structure as a tuple.

my_location = (42, 11)   # page...

The full article is available here.

You may also like

This website uses cookies to improve your experience. Accept Read More