From the very first days in our lives as programmers, we’ve all dealt with data structures: Arrays, We’d love our data structure to answer these questions as quickly as possible. ~O(1) access time (for checking a sequence) would be ideal!
We can define the Vocabulary interface like this (see here for the GitHub repo):