Surescripts Interview Question

Take out all the duplicates.