Available question text
Given a string and integer k, you repeatedly remove the first k characters and append any k characters to the end; compute the minimum positive number of such operations needed to restore the string to its original configuration. The core challenge is analyzing the position permutation induced by the remove-and-append step to find the smallest number of iterations (cycle/period) that allows the original arrangement to be reconstructed.
Related questions
Continue with questions that share topics or the same question type.
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 3029. Minimum Time to Revert Word to Initial State I
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source