WLJS LogoWLJS Notebook

FindTransientRepeat

FindTransientRepeat[list,n] returns a pair of lists {transient,repeat} where the elements of repeat occur successively at least n times after the elements of the transient part of list.

FindTransientRepeat[string,n] returns a pair of strings {transient,repeat}.

Examples

FindTransientRepeat[{1, 2, 3, 4, 5, 3, 4, 5, 3, 4, 5}, 2]
(* {{1, 2}, {3, 4, 5}} *)

Please visit the official Wolfram Language Reference for more details.

On this page