how to find repeated elements in given array

join shbcf.ru