3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = strtotime('2017-04-15 11:00:00'); $now = time(); $i = floor(($now - $start) / (12*3600)); echo $i;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tHAaB
function name:  (null)
number of ops:  15
compiled vars:  !0 = $start, !1 = $now, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'strtotime'
          1        SEND_VAL                                                 '2017-04-15+11%3A00%3A00'
          2        DO_ICALL                                         $3      
          3        ASSIGN                                                   !0, $3
    5     4        INIT_FCALL                                               'time'
          5        DO_ICALL                                         $5      
          6        ASSIGN                                                   !1, $5
    7     7        INIT_FCALL                                               'floor'
          8        SUB                                              ~7      !1, !0
          9        DIV                                              ~8      ~7, 43200
         10        SEND_VAL                                                 ~8
         11        DO_ICALL                                         $9      
         12        ASSIGN                                                   !2, $9
    9    13        ECHO                                                     !2
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.78 ms | 1006 KiB | 16 Q