A sample program to index documents.