title: Arrays and For Loops: Creating a list of numbers Greatest to Least
body: <pre><code>#include &lt;iostream&gt;
  using namespace std;
  
  int main() {
      int greatestToLeastPancakeAmount[10] = {};
      int greatestToLeastPersonNumber[10] = {};
      int pancakeAmount;
      int x;
      cout &lt;&lt; "Pancake Glutton 1.0 \n\n"; //State program's title
      cout &lt;&lt; "10 Different people ate pancakes for breakfast.. \n\n";
      x = 0;
      for(x=0;x&lt;10;x++) {
          cout &lt;&lt; "How many pancakes did person " &lt;&lt; (x + 1) &lt;&lt; " eat? &gt; ";
          cin &gt;&gt; pancakeAmount;
          greatestToLeastPersonNumber[x] = (x + 1);
          greatestToLeastPancakeAmount[x] = pancakeAmount;
          /*while(pancakeAmount &gt; greatestToLeastPancakeAmount[(x - 1)]) {
              int storeGreatestToLeastPancakeAmount = greatestToLeastPancakeAmount[(x-1)];
              int storeGreatestToLeastPersonNumber = greatestToLeastPersonNumber[(x-1)];
              greatestToLeastPancakeAmount[(x-1)] = pancakeAmount;
              greatestToLeastPersonNumber[(x-1)] = x;
              greatestToLeastPancakeAmount[x] = storeGreatestToLeastPancakeAmount;
              greatestToLeastPersonNumber[x] = storeGreatestToLeastPersonNumber;
          }*/
      }
      cout &lt;&lt; "\n\n";
      for(x=0;x&lt;10;x++) {
          cout &lt;&lt; "Person " &lt;&lt; greatestToLeastPersonNumber[x] &lt;&lt; " ate " &lt;&lt; greatestToLeastPancakeAmount[x] &lt;&lt; " pancakes!\n";
      }
      return 0;
  }
  </code></pre>
  
  <p>How do I accomplish outputting the number of people that ate the most pancakes followed by the people that at the least amount of pancakes?</p>