SAP interview question

Check duplicates in array -> algorithm