โ† Wells Fargo questions
CodingMedium

Rearrange string characters K distance apart

Filed under Wells Fargo

Given a string and an integer K, rearrange the string such that any two identical characters are at least distance K apart. Return an empty string if impossible.

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 Wells Fargo questions

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