Study
String Interview Prep Plan: What Big Tech Candidates Report
TrueInterview
October 19, 2026 · 16 min read

As of 2026-10-19, TrueInterview's bank holds 221 string coding questions reported at 25 big-tech companies, and 201 of them were last reported within the past 12 months. Their most frequent secondary tags are hashing (46), backtracking (19), stack (17) and greedy (17), with sliding-window at 11 and no string-matching algorithm in the list. Plan in blocks rather than by tag rank: a hash-map and sliding-window core first, then a stack-parsing ladder from Valid Parentheses to Basic Calculator, then spec-heavy parsing such as tokenizers and trace reconstruction. Treat KMP and rolling hashes as a last-week topic you can explain, not the centre of the plan.
Disclosure: TrueInterview is an interview-preparation product and publishes this article. Facts about other products come from their public pages on the dates listed under Sources.
Which string questions do big-tech candidates report most?
The most-linked titles are practical parsing problems and stack exercises, not textbook pattern matching. Payment Invoice Reconciliation at Stripe leads with 13 candidate write-ups, and the next five are a Stripe AI-assisted round, a sliding-window classic, a calculator, a trace parser and a tokenizer. Write-up links measure what candidates reported, not how often a company asks a question.

| Question | Where it is reported | Write-up links | Senior-or-above / junior-or-below | Family (our read) | Practise |
|---|---|---|---|---|---|
| Payment Invoice Reconciliation | Stripe | 13 | 6 / 7 | Record parsing and matching | Payment Invoice Reconciliation |
| AI-Assisted Coding Round (HackerRank + Claude) | Stripe | 12 | 6 / 6 | AI-assisted round | AI-Assisted Coding Round |
| Longest Substring Without Repeating Characters II | ByteDance, Microsoft, Meta, Amazon | 11 | 5 / 6 | Sliding window | Longest Substring Without Repeating Characters II |
| Basic Calculator I / II | ByteDance, Uber, Meta, Instacart | 11 | 5 / 6 | Stack parsing | Basic Calculator I / II |
| Stack Trace Reconstruction | Anthropic | 11 | 9 / 2 | Trace reconstruction | Stack Trace Reconstruction |
| Longest-Match Tokenizer | Google, Anthropic | 10 | 8 / 2 | Tokenizing | Longest-Match Tokenizer |
| Valid Parentheses | Amazon, NVIDIA, Meta, Oracle, ByteDance | 9 | 3 senior-or-above | Stack matching | Valid Parentheses |
| Basic Calculator | Snapchat, ByteDance, Instacart, Google, Microsoft | 9 | 2 senior-or-above | Stack parsing | Basic Calculator |
Read the table as four drills, not eight problems. The sliding-window classic is a last-seen-index map plus a left edge that only moves forward. Both calculators are operator-precedence parsing with a stack or a pending operator. Stack Trace Reconstruction, going by its title, rebuilds nested structure from a flat sequence, which is the same stack discipline applied to records. Going by its title, Longest-Match Tokenizer is likely greedy longest-prefix matching, where a trie over the vocabulary keeps each step proportional to the token length.
Breadth tells a second story. Valid Parentheses and Basic Calculator are each filed under 8 companies in the bank, and Longest Substring Without Repeating Characters II under 7. If you only have time for a handful of titles, the widely filed ones give you the most reuse across loops.
What belongs in the first week of prep?
Start with hash-map counting and sliding windows. In our view this is a teaching-order choice: hashing is the leading secondary tag on the reported questions, and the counting map you build here is the same structure the parsing and tokenizer problems reuse. Three titles cover the block: Longest Substring Without Repeating Characters II, Minimum Window Substring and Find All Anagrams in a String. Before moving on to parsing, write each of the three window invariants from memory.
The reports back each pick. Longest Substring Without Repeating Characters II was reported in an Apple phone screen as recently as 2026-09. Minimum Window Substring is filed under 3 companies and linked from 8 write-ups, with a Lyft phone-screen report from 2026-08. Find All Anagrams in a String is filed under 4 companies, though it is linked from only 2 write-ups.
Here the generic advice is right. Tech Interview Handbook's string guide names Longest Substring Without Repeating Characters among its essential questions, and its follow-up list includes Find All Anagrams in a String and Minimum Window Substring. The same guide says frequency counting decides whether two strings are anagrams in O(n) time and O(1) space.
Our take: for each window problem, write one sentence before you code: what the window guarantees, and which condition makes the left edge move. Longest Substring keeps the invariant that no character repeats inside the window. Minimum Window keeps every required count met and shrinks while that stays true. Find All Anagrams keeps a fixed width and compares counts as the window slides. If you can say those three sentences without hesitation, the variants become bookkeeping.
Why does stack-based parsing deserve its own block?
Because generic string lists bury it, and the reports do not. At Meta, stack is the top secondary tag on string questions, 7 of 26, ahead of hashing at 4. Stack-tagged questions also held a steady share of write-up links through 2026, so give parsing a full week rather than a single evening.
The share has held at 18% of links in 2026-Q1, 15% in 2026-Q2 and 17% in 2026-Q3, up from 12% in a small 2025-Q4 sample. Quarterly totals mostly reflect how many write-ups were collected, so compare shares rather than totals. Recent reports keep coming: Basic Calculator I / II appeared in a Meta phone screen in 2026-09, and Basic Calculator in a Netflix phone screen the same month.
Our take: practise the three titles as one escalating ladder in a single sitting. Valid Parentheses teaches push-and-match. Basic Calculator adds numbers, signs and nested parentheses. Basic Calculator I / II adds precedence, which you can handle by applying multiplication and division as soon as you read the next operand. Each rung reuses the previous rung's code, so a follow-up becomes an extension rather than a rewrite.
The decisions an interviewer will push on are general parsing questions. How do you treat a unary minus after an opening parenthesis? Where do you skip whitespace, and what happens to a multi-digit number at the end of the input? Can intermediate values overflow your integer type? Answer each one out loud before you write the loop, then turn each answer into a test case.
How should you prepare for spec-heavy string problems?
Treat them as their own family. Payment Invoice Reconciliation, the most-linked title, was reported in a Stripe phone screen in 2026-08, and TrueInterview's catalog tags it payment, simulation, string and api-integration. Going by its title and tags, much of the work is likely reading a spec and parsing records, so the skill to drill is careful contract handling under time.
The family is wider than one company. Stack Trace Reconstruction was reported in an Anthropic phone screen in 2026-07. GPU Credit Calculator came up in an OpenAI online assessment in 2026-08, and Format Articles Within Width in an Airbnb phone screen in 2026-05. TrueInterview's catalog also lists Shipping Cost Calculator as a Stripe phone-screen question and Processing Invoices and Payments as another Stripe coding question.
Our take: generalise the family, not the title. Payment Invoice Reconciliation is a Stripe report and Stack Trace Reconstruction an Anthropic report; what transfers is the habit of pinning down the record format before coding. For any reconciliation-style prompt, settle the matching key, what happens to partial and duplicate records, and whether money is stored in integer minor units. For any trace or log prompt, settle what an unmatched event means and whether input order can be trusted.
Where do AI-assisted rounds show up?
AI-assisted coding appears inside the string bank itself: the AI-Assisted Coding Round (HackerRank + Claude) is the second most-linked title, all from Stripe write-ups. TrueInterview says it lists AI pairing as its own round type with its own workspace. If you interview at Stripe, or at a company whose process lists an AI coding round, prepare for one round where you direct a tool and review its output on a messy spec.
The catalog also lists AI-coding entries at other companies. TrueInterview's site lists an Apple LRU Cache question from Oct 2026 filed as an AI coding round. The same catalog lists Rippling's Logger System under AI Coding, with tags that include ai-allowed and string-processing.
Our take: in an AI-assisted round, the string work moves from typing the parser to specifying and checking it. State the input contract to the tool, ask it for the edge-case tests first, and read its tokenizer or parser line by line for off-by-one errors at boundaries. In our view, your explanation of why the generated code is correct carries more of the signal than the code itself.
Do you need KMP or Rabin-Karp for interviews?
Learn them to explain, not to lead your plan. None of the most frequent tags on the reported questions is a string-matching algorithm, and PracHub's KMP guide concedes the point itself: "That is an algorithmic guarantee, not evidence that every interview requires KMP." Our take: one session in the last week is usually enough.
PracHub's guide says these questions become difficult once the interviewer moves past finding the first occurrence, and it gives KMP as O(n + m) time with O(m) extra space for exact single-pattern search. The same PracHub guide shows why overlaps matter: resetting the state to zero after a match finds only the first "aaa" in "aaaaa", while falling back to two finds starts 0, 1 and 2.
Rolling hashes are the other half of the session. The cp-algorithms page on Rabin-Karp says prefix hashes let you compare a pattern-length substring with the pattern in constant time. GeeksforGeeks notes that a hash collision occurs when two different strings share a hash value, so say how you would verify a candidate match. PracHub's guide frames the follow-ups as tracing a border chain, reporting every overlap, and knowing when rolling hash or a multi-pattern automaton fits better.
Our take: if a phone screen needs substring search, the built-in find with a stated worst case is usually the right first answer. Bring up KMP when the interviewer asks for a worst-case guarantee on repetitive input or a streaming scan.
Which round should shape your string prep?
Phone screens. String questions are reported there more than anywhere else: 129 phone-screen reports against 76 onsite and 47 online-assessment reports, and a question can appear in more than one round. Time-box your core problems to a phone-screen budget before you polish onsite variants.
| Round | Reported questions | Top secondary tags | What to add after the core |
|---|---|---|---|
| Online assessment | 47 | Hashing 11, arrays 5, greedy 4 | Hashing speed under a timer |
| Phone screen | 129 | Hashing 27, stack 14, backtracking 12 | The stack ladder and backtracking |
| Onsite | 76 | Hashing 19, backtracking 13, stack 8 | Backtracking variants such as Word Break |
Hashing leads in every round, which is why the first block comes first whatever your loop looks like. Backtracking ranks high in the tag list but clusters in phone screens and onsites, so it enters the plan through Word Break in week three rather than as its own block. Greedy ties stack in the tag list and skews senior, and it rides along with the tokenizer: longest-match tokenizing makes a greedy choice at every step. The phone screen is where stack climbs to second place, so the parsing ladder belongs before your screen, not after it. For onsites, Word Break is a useful backtracking-plus-memo drill; it is filed under 3 companies and linked from 2 write-ups.
How should you weight the plan by company?
Keep the core for everyone, then add one block for your target. In the bank, ByteDance has 27 string questions, Meta 26, Amazon and Microsoft 25 each, Google 24 and Stripe 19. Their secondary tags differ enough to change your second week.
| Company | Tag counts on its string questions | Add after the core |
|---|---|---|
| ByteDance | Hashing 7, sliding-window 5, stack 4 | Deeper window variants |
| Meta | Stack 7, hashing 4, greedy 2 | The parsing ladder, then Alien Dictionary |
| Amazon | Hashing 7, greedy 4, backtracking 4 | Hashing-plus-greedy problems |
| Microsoft | Hashing 4, sliding-window 3, stack 1 | Window variants |
| Hashing 5, trees 4, backtracking 4 | Tokenizing and tree-shaped parsing | |
| Stripe | Hashing 3, stack 1, backtracking 0 | Record parsing and an AI-assisted round |
Take a senior engineer with a Meta phone screen. Week one covers the window core. Week two runs the parsing ladder, ending on Basic Calculator I / II, which is linked from 11 write-ups, 5 of them from senior-or-above candidates. Week three adds Alien Dictionary, filed under 5 companies including Meta and linked from 8 write-ups, 4 senior-or-above, plus Valid Palindrome II, which skews senior at 5 links to 1.
Alien Dictionary is the odd one out: the input is strings, but the solution is a graph built from adjacent-word comparisons and a topological sort. Uber's phone screen reported it in 2026-09. Practise detecting the invalid case where a longer word precedes its own prefix, an edge that is easy to skip when you rush.
What changes at senior and staff level?
Level does not take you out of string questions. Candidates who reported a senior, staff-plus or manager level account for 186 write-up links, against 196 from junior, new-grad or intern candidates. Levels are self-reported on the write-ups. What shifts with level is the flavour of the problem, not whether one appears.
Senior-or-above links over-index on two-pointers (18 against 8), tries (16 against 11) and greedy (19 against 15), while arrays and trees lean junior. Junior-or-below candidates link hashing questions more, 55 against 40, and stack splits evenly at 32 against 31. Stack Trace Reconstruction and Longest-Match Tokenizer, from the table above, are the clearest senior-skewed titles. Staff-plus or manager write-ups link the AI-Assisted Coding Round twice, plus Encode And Decode, Stack Trace Reconstruction, Basic Calculator I / II, Morse Code Encoder / Decoder with Word-Break and Minimum Window Substring once each.
Our take: at senior level the bar moves from finding the algorithm to handling a messy spec cleanly. For any trace-style prompt, for example, if the input has enter and exit events, say whether a missing exit closes the open frame or invalidates the trace before you write code; for any longest-match tokenizer, say what happens when no vocabulary entry matches the next character.
Down-leveling note (our view): a strong string round rarely sets your level on its own. We think the level signal tends to come more from system design depth, the project deep dive and behavioral scope. Where a coding round contributes, it is through how you handle the changed constraint and explain trade-offs, which is exactly what the spec-heavy problems test.
Do ML and research candidates see different string questions?
Mostly the same ones, with a few model-flavoured titles. Software engineers account for 332 links to these questions, machine learning engineers 23 and research scientists 3, so the ML sample is small. Within it, hashing takes 29% of ML, AI, research and data-science links against 24% for software engineers, across 28 and 349 links.
The titles that differ are worth one session if you interview for ML roles. Trie Autocomplete / Prefix Search is linked from 4 ML or research write-ups and 5 software-engineer write-ups, and a Pinterest phone screen reported it in 2026-08. Toy Language Interpreter and Streaming Stop Token are each linked from 2 ML or research write-ups and 1 software-engineer write-up. Streaming Stop Token is the one to try if you expect inference-flavoured coding, since, going by its title, it is a matching problem over text that arrives in pieces.
Which mistakes cost the most on string problems?
In our view, many avoidable mistakes come from unstated contracts and missed corner cases rather than the wrong algorithm. Tech Interview Handbook's string guide gives the first rule plainly: "Ask about input character set and case sensitivity." Settle that before you choose a data structure, since a fixed alphabet and full Unicode lead to different counters.
Run the same corner cases every session. Tech Interview Handbook lists the empty string and strings with 1 or 2 characters, and warns that calling a counter over Latin characters O(n) space is a common mistake, because it is O(1). Add a check for indexes against bytes: if the input may hold multi-byte Unicode, say whether your positions count bytes or characters.
For matching code, PracHub's guide names three slips: reading pi[q] instead of pi[q - 1], because q is a length and indexes start at zero; incrementing the text index inside the mismatch branch, which skips a possible match start; and pointing at two loops instead of giving a monotonic-accounting proof of the bound. The same PracHub guide says empty-pattern behaviour is a contract choice that is fine if you state it before coding and test it consistently.
How we counted
Counts come from TrueInterview's question bank as of 2026-10-19 and cover questions tagged strings. TrueInterview says its questions are written up right after the interview and sorted by company and round. These are candidate-reported questions reconstructed for practice, not any company's official question list. A question can be filed under several companies and reported in several rounds, so tallies overlap, and write-up links count candidate reports, split by the level and role each candidate gave.
FAQ
What are some common string interview questions?
In candidate reports, the common ones are the ladder from Valid Parentheses to Basic Calculator, sliding-window problems such as Longest Substring Without Repeating Characters II and Minimum Window Substring, and practical parsing problems such as Payment Invoice Reconciliation and Longest-Match Tokenizer. The ranked table at the top of this article gives write-up links and practice pages for each. Classic warm-ups such as plain palindrome and anagram checks still help you learn the moves, but treat them as rehearsal rather than the target.
What are the three main types of string manipulation in interviews?
For interview planning, a useful split is counting, parsing and matching. Counting covers frequency maps and windows over substrings. Parsing covers stacks, tokenizers and record formats. Matching covers search for a pattern, from the built-in find to KMP and rolling hashes. GeeksforGeeks also stresses the distinction between a substring, which is contiguous, and a subsequence, which keeps order after deletions; that distinction decides whether a window or dynamic programming applies.
Should I prepare string questions in Java or Python?
Pick the language you write fastest under a timer, then learn how it builds and measures strings. For Java, according to one developer's Medium post, each + in a loop creates a new String object, causing heap pollution and GC overhead, so reach for StringBuilder when you assemble output. In any language, check whether its length counts bytes, code units or code points, and how slicing copies data, before an interviewer asks.
How long should a string prep plan take if I work full time?
Three weeks at about an hour a day should cover the blocks above if you already know basic hashing and recursion. Spend the first week on windows, the second on the parsing ladder and one spec-heavy simulation, and the third on your target company's block plus one matching session. If you have less time, cut the matching session first and keep the parsing ladder, since the reports weight parsing far more heavily.
Are hash table and recursion questions part of string prep?
Yes, and they overlap heavily. As the round table shows, hashing leads the secondary tags in every round, so hash-map counting is the base skill for this whole topic. Recursion shows up through backtracking and through nested parsing such as parentheses in a calculator, which you can write either recursively or with an explicit stack. Practising both forms of the calculator is a good way to cover recursion without a separate block.
Your practice plan
A three-week plan for someone working full time, about an hour a day:
- Week one, window core. Solve Longest Substring Without Repeating Characters II, Minimum Window Substring and Find All Anagrams in a String back to back, and write each window invariant in one sentence before coding.
- Week one, corner cases. In every session, test the empty string, a single character, repeated characters, mixed case and a non-Latin character before you call a solution done.
- Week two, parsing ladder. Work Valid Parentheses, then Basic Calculator, then Basic Calculator I / II in one sitting, timed to a phone-screen budget, adding operators and parentheses one rung at a time.
- Week two, spec-heavy simulation. Do one timed run of Payment Invoice Reconciliation or Stack Trace Reconstruction, narrating the input format and its edge cases before writing code, then change one constraint and redo it.
- Week three, company block. Add the block from the company table: Alien Dictionary for Meta or Uber, Longest-Match Tokenizer for Google or Anthropic, or Word Break for onsite backtracking.
- Week three, matching session. Build a KMP prefix table by hand on a repetitive pattern, report overlapping matches, and explain when a rolling hash fits better. Then re-solve any earlier problem where you could not state the invariant first.
Sources
- TrueInterview question bank — string coding at big-tech companies — counted 2026-10-19
- String cheatsheet for coding interviews | Tech Interview Handbook — checked 2026-10-19
- Coding Interview Questions by Company · TrueInterview — checked 2026-10-19
- Real FAANG Interview Questions by Company · TrueInterview — checked 2026-10-19
- String Matching Interview Questions: KMP Prefix Tables and Overlapping Matches | PracHub Knowledge Hub — checked 2026-10-19
- Rabin-Karp for String Matching - Algorithms for Competitive Programming — checked 2026-10-19
- String Interview Questions - GeeksforGeeks — checked 2026-10-19
- Medium — checked 2026-10-19
Last reviewed: 2026-10-19.