String manipulation related

Asked atGoogle
1Give yourself 5 minutes
2Answer out loud, not in your head
3Then compare with the answer below
0
Stuck? Show a way to structure it+
  1. 01Request the concrete input-output examples and mutation rules.
  2. 02Select a representation appropriate for edits and encoding.
  3. 03Use one-pass or two-pointer state with a stated invariant.
  4. 04Test boundary inputs and report time and output-space costs.

Reference answer

Then expect these follow-ups

  • What invariant fits a filtering transform?

    Tests: reasoning

  • How do you test Unicode safely?

    Tests: robustness

Free to read · better with Enzo

Practice this out loud with Enzo

Enzo runs it as a mock interview, pushes back with follow-ups, and grades you on the rubric.

Next question