PyDocs

Nav

Development Tools

Tuple

typing

dataDeprecated 3.9
Deprecated since 3.9. builtins.tuple now supports subscripting ([]). See PEP 585 and Generic Alias Type.
Deprecated alias to builtins.tuple.

Tuple[X, Y] is the cross-product type of X and Y.

Example: Tuple[T1, T2] is a tuple of two elements corresponding
to type variables T1 and T2.  Tuple[int, float, str] is a tuple
of an int, a float and a string.

To specify a variable-length tuple of homogeneous type, use Tuple[T, ...].
0 Examples
No examples for typing/Tuple.
See Also
No see-alsos for typing/Tuple
0 Notes
No notes for Tuple