tuple: 元组被定义后无法被修改 count(): #count(obj) 统计obj在元组中出现的次数 tup = (1,2,3,4,5,6,5,5,5,5,5,5,5) print(tup.count(6)) len(): #len(tuple) 统计tuple的元素个数 tup = (1,2,3,4,5,6,7,8) print(len(tup)) index(): #index(x,[start,[end]]) 返回x在tuple中第一次出现的索引 tup = (1,2,3,4,5,…