Mental Model
We want to check if a long word can be split into smaller valid words from a dictionary. We try breaking it step by step and remember what parts can be formed.
Analogy: Imagine you have a long sentence without spaces and a list of known words. You try to put spaces in places so that every piece is a known word, like solving a puzzle by fitting pieces together.
s t r i n g ā Dictionary: ["cat", "cats", "and", "sand", "dog"]
