def lst_ope(): lst = [1, 2, 3] print operator.indexOf(lst, 2) # 1 lst1 = [1, 2, 3, 2] print operator.countOf(lst1, 2) # 2