title: Subtracting arrays more efficiently
body: <p>I have a few questions. Got this array:</p>
  
  <pre><code>$array_1  = array(
      "1" =&gt; "4",
      "2" =&gt; "8",
      "3" =&gt; "12",
      "4" =&gt; "16",
      "5" =&gt; "20",
      "6" =&gt; "24",
      "7" =&gt; "28",
      "8" =&gt; "32",
      "9" =&gt; "36",
      "10" =&gt; "40",
      "11" =&gt; "44",
      "12" =&gt; "48",
      "13" =&gt; "52",
      "14" =&gt; "56",
      "15" =&gt; "60",
      "16" =&gt; "64",
      "17" =&gt; "68",
      "18" =&gt; "72",
      "19" =&gt; "76",
      "20" =&gt; "80",
      "21" =&gt; "84",
      "22" =&gt; "88",
      "23" =&gt; "92",
      "24" =&gt; "96",
      "25" =&gt; "100",
      "26" =&gt; "104",
      "27" =&gt; "108",
      "28" =&gt; "112",
      "29" =&gt; "116",
      "20" =&gt; "120",
      "31" =&gt; "124",
      "32" =&gt; "128",
      "33" =&gt; "132",
      "34" =&gt; "136",
      "35" =&gt; "140",
      "36" =&gt; "144",
      "37" =&gt; "148",
      "38" =&gt; "152",
      "39" =&gt; "156",
      "40" =&gt; "160",
      "41" =&gt; "164",
      "42" =&gt; "168",
      "43" =&gt; "172",
      "44" =&gt; "176",
      "45" =&gt; "180",
      "46" =&gt; "184",
      "47" =&gt; "188",
      "48" =&gt; "192",
      "49" =&gt; "196",
      "50" =&gt; "200"
  );
  </code></pre>
  
  <p>I would like to subtract <code>$array_1</code> by 1,2,3,4 into multiple arrays. So far I have done it by having other arrays:</p>
  
  <pre><code>$array_2  = array(
      "1" =&gt; "1",
      "2" =&gt; "1",
      ...
      "49" =&gt; "1",
      "50" =&gt; "1"
  );
  
  $array_3  = array(
      "1" =&gt; "2",
      "2" =&gt; "2",
      ...
      "49" =&gt; "2",
      "50" =&gt; "2"
  );
  // All the way to values of 4
  </code></pre>
  
  <p>Then with this I would do an <code>array_diff</code> to get the lowered value.</p>
  
  <p>I was wondering firstly is there a better way (more efficient) to have the array subtract rather than repeat the 1,2,3,4 50 times each.</p>
  
  <p>Secondly, is there a more efficient way to have <code>$array_1</code> have the values of multiple of 4 up to 200?</p>
  
  <p>Thirdly, do I need an array to subtract from <code>$array_1</code> to lower the value? Is there a better way to this like: <code>$array_1 - 1</code></p>
  
  <p><strong>INTENDED OUTPUT</strong></p>
  
  <pre><code>// $array_1 - $array_2 (value of 1)
  $minus_one = array(
      "1" =&gt; "3",
      "2" =&gt; "7",
      "3" =&gt; "11",
      ...
  );
  // $array_1 - $array_3 (value of 2)
  $minus_two = array(
      "1" =&gt; "2",
      "2" =&gt; "6",
      "3" =&gt; "10",
      ...
  );
  // $array_1 - $array_4 (value of 3)
  $minus_one = array(
      "1" =&gt; "1",
      "2" =&gt; "4",
      "3" =&gt; "8",
      ...
  );
  </code></pre>