added index number to output