Katkat
Online Assessment

Online Assessment with a Balanced-Window and Monotonic-Stack Problem

MicrosoftSoftware Engineer · Online Assessment · Mar 2026

Q1 — problem You're given a permutation p of length n. For each k (1 ≤ k ≤ n), determine whether there's a contiguous subarray that is exactly a permutation of the numbers 1 through k (order doesn't matter). If one exists, call k "balanced." The final output is a length-n binary string, where the k-th digit says whether k is balanced. Q1 — approach The key isn't to enumerate subarrays — it's to f…

Shared by a candidate · reported Mar 2026. Interview formats change; use it as a guide, not a script.