1. 程式人生 > >Python 元組內置函數

Python 元組內置函數

idt reference http 最大值 style ble width 比較 python元組

Python元組包含了以下內置函數

序號方法及描述
1 cmp(tuple1, tuple2)
比較兩個元組元素。
2 len(tuple)
計算元組元素個數。
3 max(tuple)
返回元組中元素最大值。
4 min(tuple)
返回元組中元素最小值。
5 tuple(seq)
將列表轉換為元組。

Python 元組內置函數