ifraq 0 Newbie Poster

UniqueElements(A[0...n-1])
//Determines Whether all the elements in a given array are distinct
//Input: An array A[0...n-1]
//Output: Returns "True" if all the elements in A are distinct &"False" oterwise
for i =0 to n-2 do
for j=i+1 to n-1 do
if A[i]=A[j] return false
return true

Thanks