fork download
  1. <?php
  2. $month_name = [
  3. ["months" =>"april"],
  4. ["months" =>"may"],
  5. ["months" =>"june"],
  6. ["months" =>"july"],
  7. ["months" =>"august"],
  8. ["months" =>"september"],
  9. ["months" =>"october"],
  10. ["months" =>"november"],
  11. ["months" =>"december"],
  12. ["months" =>"january"],
  13. ["months" =>"february"],
  14. ["months" =>"march"]
  15. ];
  16.  
  17.  
  18. $months = [
  19. ["months" => "april"],
  20. ["months" => "may"],
  21. ["months" => "october"]
  22. ];
  23.  
  24. $due_months = array_diff_assoc($month_name, $months);
  25. print_r($due_months);
Success #stdin #stdout #stderr 0.01s 82560KB
stdin
Standard input is empty
stdout
Array
(
    [3] => Array
        (
            [months] => july
        )

    [4] => Array
        (
            [months] => august
        )

    [5] => Array
        (
            [months] => september
        )

    [6] => Array
        (
            [months] => october
        )

    [7] => Array
        (
            [months] => november
        )

    [8] => Array
        (
            [months] => december
        )

    [9] => Array
        (
            [months] => january
        )

    [10] => Array
        (
            [months] => february
        )

    [11] => Array
        (
            [months] => march
        )

)
stderr
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24
PHP Notice:  Array to string conversion in /home/PmMhqb/prog.php on line 24