Review: added logic to final index