Insert documents and check them against boolean predicates
Build a small server with two calls: insert_doc(filename) stores a document, and check_contains(filename, predicate) answers whether the document satisfies a predicate over terms, such as a || b || c or a && b || c.
Parse the predicate with the usual precedence, evaluate it against the document's terms, and discuss how you would index documents so that checks stay fast.
No answer yet. Write the first one; the best answer gets endorsed.
