title: Array a[i] prints in descending order, but my logic is for ascending order
body: <p>Can you please tell me why I am always getting array <code>a[i]</code> in descending order only? Please help.   </p>
  
  <pre><code>for(i=0;i&lt;10;i++)  
  {    
      for (j=0;j&lt;10;j++)
      {   
         if(a[i]&gt;=a[j])
         { 
            temp=a[i];
            a[i]=a[j];
            a[j]=temp;
         }
      }
  }
  </code></pre>