LeetCode 208: Implement Trie (Prefix Tree) in Python

Subtitle / Summary LeetCode 208 is the fixed-interface version of the Trie template. We will derive the node fields and lookup invariant first, then fit them into Trie(), insert, search, and startsWith. Reading time: 10-12 min Tags: Hot100, Trie, prefix tree, LeetCode 208 SEO keywords: LeetCode 208, Implement Trie, Prefix Tree, Python Trie, startsWith, is_end Meta description: A pressure-first Python guide to LeetCode 208 covering Trie nodes, children, is_end, insert, search, startsWith, and submission checks. A - Algorithm Problem setup: design a prefix-tree word index The task is to design a mutable word index. The index starts empty, then receives words one by one, and must answer two kinds of lookup: ...

June 25, 2026 · 12 min · map[name:Jeanphilo]

Trie Template Guide: Node Fields, Child Traversal, and Loop Invariants

Subtitle / Summary Build a Trie from a small word-index task instead of memorizing the final class. The key model is: a node represents a prefix reached by a path, and is_end decides whether that prefix is also a complete word. Reading time: 10-12 min Tags: Hot100, Trie, prefix tree, string SEO keywords: Trie template, Python Trie, prefix tree, children, is_end, LeetCode 208 Meta description: A minimal Python Trie template that derives node fields, child traversal, end markers, prefix search, and insert/search loop invariants. A - Algorithm: Start From A Small Task Tiny task: build a word index for lookup and autocomplete Suppose we are building a small word index for a search box. After adding: ...

June 25, 2026 · 10 min · map[name:Jeanphilo]

Hot100: Palindrome Partitioning (Backtracking / Palindrome Table ACERS Guide)

Subtitle / Summary 131. Palindrome Partitioning is not hard because of recursion alone. The real challenge is separating two concerns clearly: where the next cut starts, and whether the current substring is a valid palindrome. Reading time: 15-18 min Tags: Hot100, backtracking, string, palindrome, DP SEO keywords: Palindrome Partitioning, backtracking, palindrome DP, string partition, LeetCode 131 Meta description: Learn LeetCode 131 by building the solution from scratch, using suffix-based DFS plus a precomputed palindrome table. A — Algorithm Problem Restatement Given a string s, partition it so that every substring in the partition is a palindrome. Return all possible palindrome partitionings of s. ...

April 19, 2026 · 15 min · map[name:Jeanphilo]

LeetCode 1456: Maximum Number of Vowels in a Substring of Given Length (ACERS Guide)

Subtitle / Summary A standard fixed-window counting problem. This ACERS guide explains the sliding-window model, engineering use cases, and runnable multi-language solutions. Reading time: 10–12 min Tags: sliding window, string, fixed window SEO keywords: Maximum Number of Vowels, Sliding Window, Fixed Window Meta description: Fixed-window sliding count for maximum vowels with engineering applications. A — Algorithm Problem Restatement Given a string s and an integer k, return the maximum number of vowels in any substring of length k. ...

January 20, 2026 · 7 min · map[name:Jeanphilo]