PageRenderTime 45ms CodeModel.GetById 19ms RepoModel.GetById 0ms app.codeStats 0ms

/test/subjects/optimization/array_pop.php

http://phc.googlecode.com/
PHP | 14 lines | 8 code | 4 blank | 2 comment | 0 complexity | ce5785e7804be6aa0953a640598a8c5a MD5 | raw file
Possible License(s): GPL-2.0, 0BSD, BSD-3-Clause, Unlicense, MPL-2.0-no-copyleft-exception, LGPL-2.1
  1. <?php
  2. // try it without arry_pop
  3. $a = array (1, 2, 3, 4);
  4. $b = $a[$argc];
  5. $a[$argc] = NULL;
  6. // same thing
  7. $x = array (1, 2, 3, 4);
  8. $y = array_pop ($x);
  9. var_dump ($a, $b, $x, $y);
  10. ?>