3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( '1/10/2014', '1/11/2014', '1/12/2014', '1/13/2014', '1/14/2014' ); foreach ($array as $key => $date) { $unixdate = strtotime($date); if ($unixdate < time()) { unset($array[$key]); } } print_r($array);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 14
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 14
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 13
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 13
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
filename:       /in/VS6IF
function name:  (null)
number of ops:  19
compiled vars:  !0 = $array, !1 = $date, !2 = $key, !3 = $unixdate
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   10     1      > FE_RESET_R                                       $5      !0, ->14
          2    > > FE_FETCH_R                                       ~6      $5, !1, ->14
          3    >   ASSIGN                                                   !2, ~6
   12     4        INIT_FCALL                                               'strtotime'
          5        SEND_VAR                                                 !1
          6        DO_ICALL                                         $8      
          7        ASSIGN                                                   !3, $8
   14     8        INIT_FCALL                                               'time'
          9        DO_ICALL                                         $10     
         10        IS_SMALLER                                               !3, $10
         11      > JMPZ                                                     ~11, ->13
   16    12    >   UNSET_DIM                                                !0, !2
   10    13    > > JMP                                                      ->2
         14    >   FE_FREE                                                  $5
   22    15        INIT_FCALL                                               'print_r'
         16        SEND_VAR                                                 !0
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.64 ms | 1395 KiB | 19 Q