KatInterview

Topic

Strings interview problems

Parsing, matching, palindromes and string transforms. 227 original problems, each with hidden test cases you can run in the browser.

Problems227

60 easy154 medium13 hard

Showing 211–227 of 227 results

  • Build a memory-efficient Python generator that parses log records with timestamps and key-value pairs, handling quoted strings with escapes.

    Model answerparsinggeneratorsstring-processingtext-processing
  • Tests whether a candidate can count the minimum number of single-character insertions or deletions needed to transform a string into any palindrome.

    Auto-gradedstringsdynamic programmingedit operations
  • Tests string manipulation and numeric logic to determine if a number is palindromic and compute the next larger palindrome efficiently.

    Auto-gradedpalindromestring-manipulationgreedy
  • Tests whether candidates can implement a precise single-pass parser that accepts only well-formed integers, decimals, and scientific notation strings.

    Auto-gradedstringsparsingtwo-pointers
  • Tests basic control flow, modular arithmetic, and string formatting by transforming numbers according to divisibility conditions.

    Auto-gradedconditionalsmoduloiteration
  • Tests recursive parsing, the distributive property of multiplication over addition, and constructing expanded expressions from nested operations.

    Auto-gradedparsingrecursionstring-manipulation
  • Tests sliding window technique with character frequency tracking to find the smallest substring containing exactly k distinct characters.

    Auto-gradedsliding-windowhash-maptwo-pointers
  • Remove all paths that match or fall under any deletion target in a hierarchical filesystem-like structure.

    Model answertrieprefix-matchingstring-processing
  • Tests hash-based frequency counting for strings and grouped numeric aggregation with exact average comparison.

    Auto-gradedhash-mapstring-manipulationaggregation
  • Tests prefix-tree construction, greedy string scanning, and longest-match selection for token-based text transformation.

    Auto-gradedtriegreedystring-processing
  • Tests the ability to parse and expand a run-length encoded string that contains arbitrarily nested bracket groups, combining stack-based parsing with string manipulation.

    Auto-gradedstringsparsingstackrun-length encoding
  • Tests the ability to tokenize a raw arithmetic string into numbers and operators, then evaluate left-to-right respecting only + and - operations.

    Auto-gradedstringstokenizingparsing
  • Tests whether a candidate can reduce a multi-length sliding-window problem to a single window size and efficiently track distinct-character counts.

    Auto-gradedsliding-windowhash-mapstrings
  • Tests understanding of palindromic structure by finding the minimum characters to append to a string to make the whole string a palindrome.

    Auto-gradedstringspalindrometwo pointers
  • Tests the sliding window pattern with frequency counting to find the shortest substring of one string that covers every character (with multiplicity) of another.

    Auto-gradedsliding-windowhash-maptwo-pointers
  • Tests anagram-grouping on structured strings with a prefix/suffix schema, requiring careful key extraction, normalization, and tie-breaking for sorted output.

    Auto-gradedstringsanagram groupingsortingparsing
  • Tests the ability to canonicalize strings into sorted-character keys and cluster words that are anagrams of each other, with a precise tie-breaking rule for deterministic output.

    Auto-gradedstringsanagramshash mapsorting

More topics