3v4l.org

run code in 300+ PHP versions simultaneously
<?php for($i = 1; $i < 10; $i++) { $today = strtotime("+$i days"); $quote_for = strtotime('+1 Weekday',strtotime("+$i days")); $diff = ($quote_for - $today)/86400; // difference in days echo "On " . date('l \t\h\e jS',$today) . " the shipping quote will be for " . date('l \t\h\e jS', $quote_for) . " which is " . abs($diff) . "days " . ($diff >0?"after":"before") . " today. \n"; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 49
Branch analysis from position: 49
2 jumps found. (Code = 44) Position 1 = 51, Position 2 = 2
Branch analysis from position: 51
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 2
2 jumps found. (Code = 43) Position 1 = 42, Position 2 = 44
Branch analysis from position: 42
1 jumps found. (Code = 42) Position 1 = 45
Branch analysis from position: 45
2 jumps found. (Code = 44) Position 1 = 51, Position 2 = 2
Branch analysis from position: 51
Branch analysis from position: 2
Branch analysis from position: 44
2 jumps found. (Code = 44) Position 1 = 51, Position 2 = 2
Branch analysis from position: 51
Branch analysis from position: 2
filename:       /in/YdlEh
function name:  (null)
number of ops:  52
compiled vars:  !0 = $i, !1 = $today, !2 = $quote_for, !3 = $diff
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 1
          1      > JMP                                                      ->49
    5     2    >   INIT_FCALL                                               'strtotime'
          3        ROPE_INIT                                     3  ~6      '%2B'
          4        ROPE_ADD                                      1  ~6      ~6, !0
          5        ROPE_END                                      2  ~5      ~6, '+days'
          6        SEND_VAL                                                 ~5
          7        DO_ICALL                                         $8      
          8        ASSIGN                                                   !1, $8
    6     9        INIT_FCALL                                               'strtotime'
         10        SEND_VAL                                                 '%2B1+Weekday'
         11        INIT_FCALL                                               'strtotime'
         12        ROPE_INIT                                     3  ~11     '%2B'
         13        ROPE_ADD                                      1  ~11     ~11, !0
         14        ROPE_END                                      2  ~10     ~11, '+days'
         15        SEND_VAL                                                 ~10
         16        DO_ICALL                                         $13     
         17        SEND_VAR                                                 $13
         18        DO_ICALL                                         $14     
         19        ASSIGN                                                   !2, $14
    7    20        SUB                                              ~16     !2, !1
         21        DIV                                              ~17     ~16, 86400
         22        ASSIGN                                                   !3, ~17
    9    23        INIT_FCALL                                               'date'
         24        SEND_VAL                                                 'l+%5Ct%5Ch%5Ce+jS'
         25        SEND_VAR                                                 !1
         26        DO_ICALL                                         $19     
         27        CONCAT                                           ~20     'On+', $19
   10    28        CONCAT                                           ~21     ~20, '+the+shipping+quote+will+be+for++'
         29        INIT_FCALL                                               'date'
         30        SEND_VAL                                                 'l+%5Ct%5Ch%5Ce+jS'
         31        SEND_VAR                                                 !2
         32        DO_ICALL                                         $22     
         33        CONCAT                                           ~23     ~21, $22
   11    34        CONCAT                                           ~24     ~23, '+which+is+'
         35        INIT_FCALL                                               'abs'
         36        SEND_VAR                                                 !3
         37        DO_ICALL                                         $25     
         38        CONCAT                                           ~26     ~24, $25
         39        CONCAT                                           ~27     ~26, 'days+'
         40        IS_SMALLER                                               0, !3
         41      > JMPZ                                                     ~28, ->44
         42    >   QM_ASSIGN                                        ~29     'after'
         43      > JMP                                                      ->45
         44    >   QM_ASSIGN                                        ~29     'before'
         45    >   CONCAT                                           ~30     ~27, ~29
         46        CONCAT                                           ~31     ~30, '+today.+%0A'
         47        ECHO                                                     ~31
    3    48        PRE_INC                                                  !0
         49    >   IS_SMALLER                                               !0, 10
         50      > JMPNZ                                                    ~33, ->2
   13    51    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.32 ms | 1400 KiB | 19 Q