Filter Duplicates While Preserving Order

Implement filter_duplicates(data), which returns the values of data with duplicates removed while preserving the relative order of the first occurrence of every value.

Parameter:

  • `data...

Example

Unlock to view complete problem details

and practice with sample input/output

Was this article helpful?

View Test Cases & Run Code requires membership

Standard Input
Execution Result: