Implementing word break problem (http://thenoisychannel.com/2011/08/08/retiring-a-great-interview-problem) in O(n) time using aho-corasick.
To keep this example simple, I avoid using interfaces, namespaces, custom alocators, templates and suppose that alphabet consist only of small characters('a'-'z').