0

I got this test online last week.
here is an example:
given this array:
{ 1 , 2 , 4 , 5 , 1 , 4 , 6 , 2 , 1 , 4 }
on condition that
index(x) < index (y)
find the number of possible pairs (x,y).
where x = y.
the answer would be:
count = 7 - (0,4), (0,8), (4,8), (1,7), (2,5), (2,9), (5,9)
the...