def find_increasing_sequences(worder):
 items = iter(worder)
 (a, b) = (None, next(items, None))
 result = [b]
 while (b is not None):
  (a, b) = (b, next(items, None))
  if ((b is not None) and ((a + 1) == b)):
   result.append(b)
  else:
   if (len(result) > 1):
    (yield tuple(result))
   result = [b]

def find_increasing_sequences ( worder ) : items = iter ( worder ) ( a , b ) = ( None , next ( items , None ) ) result = [ b ] while ( b is not None ) : ( a , b ) = ( b , next ( items , None ) ) if ( ( b is not None ) and ( ( a + 1 ) == b ) ) : result . append ( b ) else : if ( len ( result ) > 1 ) : ( yield tuple ( result ) ) result = [ b ]
given the *worder* list .