def index ( self , item ) : for i , x in enumerate ( self . iter ( ) ) : if x == item : return i return None
python get index of element each time it appears in list
Not recommended for use on large lists due to time complexity but it works
def index(self, item):
        """ Not recommended for use on large lists due to time
            complexity, but it works

            -> #int list index of @item
        """
        for i, x in enumerate(self.iter()):
            if x == item:
                return i
        return None