在 Python 中,元组是一种有序且不可变的序列,用于存储多个元素。元组使用小括号 () 来定义,元素之间用逗号 , 分隔。例如:
()
,
my_tuple = (1, 'apple', 3.14) print(my_tuple)