store slice and index