title: finding index of max value in an array in C
body: <p>I want to find index of max value in array in C.</p>
  
  <p>I write this code example:</p>
  
  <pre><code>maks=0;
  for(i=0;i&lt; N * N;i++) {
      if(array[i]&gt;maks) {
          maks=(int) array[i];
          k=i;
      }
  }
  </code></pre>
  
  <p>But this isn't work properly.Could you advise me another example please?</p>
  
  <p>Best Regards...</p>