← Walmart questions

Find first index of a special substring of length k

Filed under Walmart

Given a string of length n and q queries where each query provides a length k, find the first index of a special substring of length k that has not repeated itself anywhere else in the string.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Walmart questions

Collected from public candidate posts and coding forums. Updated Nov 2026.