title: how to sort a structure array in VC 6.0
body: <p>here's the question. i've defined a struct:</p>
  
  <pre><code>typedef struct {
  
          long t;
          long M;
          long double coeff;
  } Info;
  </code></pre>
  
  <p>and i can only know the number of the structures in the following program, thus i wrote:</p>
  
  <p>Info <em>p = (Info</em>) malloc (sizeof(Info) * sum );  (where sum is a long integer)</p>
  
  <p>and now i want to sort the structure array according to 'coeff' in ascending order. </p>
  
  <p>how could i achieve it in VC++6.0?</p>
  
  <p>thanks a lot!</p>