
Re: second largest element in a matrix
Posted:
May 4, 2013 7:14 PM


El jueves, 18 de septiembre de 2008 21:46:01 UTC5, Oluwa KuIse escribió: > Hello, > Can anyone pls tell me how I can find the second (or third) largest element in a matrix AND its position. The max function gives the largest element and its position but how do I find the second largest element and its position?
IF for example, i have a matrix [3,1,1,0,2,0] and want to make a function to display the first and second largest value, how could i write it?

