title: Copying elements from one array to another c++
body: <p>I have looked and looked and am still lost on how to copy or get elements from an array and put them into new arrays ( divide and conquer is the goal).</p>
  
  <p>I have an array that generates 100 random numbers. I need to split the random numbers into 4 smaller arrays obviously containing 25 elements and not have any duplicates. I have read about using pointers, but honestly I don't understand why even use a pointer. Why do I care about another variables address? </p>
  
  <p>I don't know how to do this. Here is my code so far:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;time.h&gt;
  #include &lt;stdlib.h&gt;
  
  using namespace std;
  
  
  int main()
  {
    // Seed the random number generator
  
    srand(time(NULL));
  
    //create an array to store our random numbers in
  
    int Orignumbers[100]    = {};
    // Arrays for the divide and conquer method
    int NumbersA   [25]     = {};
    int NumbersB   [25]     = {};
    int NumbersC   [25]     = {};
    int NumbersD   [25]     = {};
  
  
    //Generate the random numbers
    for(int i =0; i &lt; 100; i++)
    {
      int SomeRandomNumber = rand() % 100 + 1;
  
    // Throw random number into the array
  
    Orignumbers[i] = SomeRandomNumber;
  
    }
  
  //  for(int i = 0; i &lt; ) started the for loop for the other arrays, this is where I am stuck!!
  
    // Print out the random numbers
    for(int i = 0; i &lt; 100; i++)
    {
      cout &lt;&lt; Orignumbers[i] &lt;&lt; " , ";
    }
  
  }
  </code></pre>