title: Locating the largest element in the row of a multi dimensional array
body: <p>I'd like to subtract the highest element in this 5x2 matrix, with it's subsequent element, in the other column. </p>
  
  <p>For ex: the highest element right now is 150, whose location is (4,1). I'd like to subtract <strong>150</strong> with <strong>89</strong>, which is it's subsequent element. In the same way if the highest element belonged to the first column, then it should subtract itself from the element in the next column.</p>
  
  <p>Thanks </p>
  
  <pre><code>int big=0,lead=0,m,n;
  
  int a[5][2]={140,82,89,150,110,110,112,106,88,90};
  
  for(int j=0; j&lt;5; j++)
  {
      for(int i=0 ; i&lt;2; i++)
      {
          m=j;
          n=i;
  
          if(a[j][i] &gt; big)
  
           {
               big = a[j][i];
  
               if(big == a[j][i])
  
              {
                   lead = big-a[j][1];
              }
  
               else
  
              {
                  lead = big-a[1][i];
              }
          }
      }
  }
  
           cout&lt;&lt;big&lt;&lt;"\n"&lt;&lt;lead&lt;&lt;"\n"&lt;&lt;m&lt;&lt;","&lt;&lt;n&lt;&lt;endl;
  }
  </code></pre>