Edmunds.com Interview Question

Why does this output have duplicates