A=[1,2,3,2,1,5,1,2];%expample:any vectortable=tabulate(A);[F,I]=max(table(:,2));I=find(table(:,2)==F);result=table(I,1)
yvg