finishing the index