Using variable-arity fns to simplify indexing code.