Array

can you please solve this?

I have array with common elements and I have to sort and collect common elements.

For Example

MyArray=[1,3,4,8,10,88,98,101,3,10,15,1,3,4]

So here numbers like 1,3,4,10 are repeating. I have to just take these four numbers from MyArray