now it prints the index in front