tupleの読み方

tupleの読み方

pythonの構文の1つである「tuple」の読み方を掲載してます。

読み⽅

タプル」と読みます。

tupleとは

pythonでは、編集のできないリストのようなものとなります。

tuple = (1, 2, 3)

tuple[0]=2
# TypeError: 'tuple' object does not support item assignment