3v4l.org

run code in 300+ PHP versions simultaneously
<?php $cadastro = '2014-04-01'; $expira = date('Y-m-d', strtotime($cadastro. ' + 182 days')); $diff = $expira - strtotime(date('Y-m-d')); $daysleft=floor($diff/(60*60*24)); echo "$daysleft days left"; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tnls2
function name:  (null)
number of ops:  27
compiled vars:  !0 = $cadastro, !1 = $expira, !2 = $diff, !3 = $daysleft
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '2014-04-01'
    3     1        INIT_FCALL                                               'date'
          2        SEND_VAL                                                 'Y-m-d'
          3        INIT_FCALL                                               'strtotime'
          4        CONCAT                                           ~5      !0, '+%2B+182+days'
          5        SEND_VAL                                                 ~5
          6        DO_ICALL                                         $6      
          7        SEND_VAR                                                 $6
          8        DO_ICALL                                         $7      
          9        ASSIGN                                                   !1, $7
    5    10        INIT_FCALL                                               'strtotime'
         11        INIT_FCALL                                               'date'
         12        SEND_VAL                                                 'Y-m-d'
         13        DO_ICALL                                         $9      
         14        SEND_VAR                                                 $9
         15        DO_ICALL                                         $10     
         16        SUB                                              ~11     !1, $10
         17        ASSIGN                                                   !2, ~11
    7    18        INIT_FCALL                                               'floor'
         19        DIV                                              ~13     !2, 86400
         20        SEND_VAL                                                 ~13
         21        DO_ICALL                                         $14     
         22        ASSIGN                                                   !3, $14
    8    23        NOP                                                      
         24        FAST_CONCAT                                      ~16     !3, '+days+left'
         25        ECHO                                                     ~16
    9    26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.91 ms | 1387 KiB | 19 Q