title: Random number in a range inside an Array
body: <p>I'm trying to get random a random number between certain ranges in each column in an array so as to mimic a Bingo card. </p>
  
  <p>The first   column should contain numbers from 1 to 10, the second  column  numbers from 11 to 20, the third, 21 to 30 and so on up until the last column,  which contains numbers from 81 to 90.</p>
  
  <p>Here is my revised code based on answers below:</p>
  
  <pre><code> for (row = 0; row&lt;3; row++)
              {
                  for (col = 0; col&lt;9; col++)
                  {
                      if (col == 0)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 1st col
  
                      else if (col == 1)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 2nd col
  
                      else if (col == 2)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 3rd col
  
                      else if (col == 3)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 4th col
  
                      else if (col == 4)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 5th col
  
                      else if (col == 5)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 6th col
  
                      else if (col == 6)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 7th col
  
                      else if (col == 7)
                      {
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 8th col
  
                      else if (col == 8)
                      {   
                          bingoCard[row][col] = (rand() % 10) + 1 + col * 10;
  
                      }//end of 9th col
  
                  }// end col for
  </code></pre>
  
  <p>The code now outputs the following : </p>
  
  <pre><code>***New Game***
  How many players?
  1
  
  Player : 1 's card
  
  
  
  2       18      25      5       16      26      8       17      22
  5       16      26      8       17      22      35      43      54
  8       17      22      35      43      54      63      73      82
  </code></pre>
  
  <p>It's still way off once it goes past the 3rd column? From there one value in each column is right? </p>