Some common data structures and algorithms as snippets