Tries, tokenizers and command parsing
Explore prefix lookup, command completion and parsing small expressions using constrained memory.
View lesson accessAll lessonsWhat the lesson covers
The course lesson is called The command line that finds commands. The service tool needs a command line: type hea and it completes to heater, split the line into arguments, and evaluate small expressions like rate*2+1.
- trie
- prefix lookup
- memory layouts
- tokenizer
- expression parser
Before you start
Question to think about: How will a parser distinguish a complete command from a partial or invalid prefix?
Preparation exercise: Define an input grammar and a bounded set of tests for empty, truncated and unrecognized tokens.
This is an original public study prompt, not the paid lesson or its solution. The interactive course contains the walkthroughs, labs, exercises and recaps.
Read the free embedded C articles for additional practice.
Test your understanding
Practice free firmware interview questions and mock interviews · Assess your readiness