Hey thanks for your reply!!!!!!!!1

The array i am using is ( 3*5)

a x a p m

m m m m c

c p d y a

The comparison should go this way,

I should take column 1 and should compare with other columns regardless of the order!!!!

If its same then i should cluster column1 and the other columns which are same as column 1 into another array(Clustering).

If its not same then column1 will be a separate array!!!!!

Similarly i should compare the other columns!!!!!!!!!!!!!!!