3v4l.org

run code in 300+ PHP versions simultaneously
<?php for ($i = 1; $i <= 31; $i++) { if ($i < 10){ $day = '0'.$i; if( ($i+1) < 10 ) $next_day = '0'.($i+1); else $next_day=$i+1; } else{ $day = $i; $next_day = ($i+1); } echo "$day $next_day".PHP_EOL; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 25
Branch analysis from position: 25
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 2
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 2
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 16
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 13
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 19
Branch analysis from position: 19
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 2
Branch analysis from position: 27
Branch analysis from position: 2
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 19
Branch analysis from position: 19
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 2
Branch analysis from position: 27
Branch analysis from position: 2
filename:       /in/3GEWa
function name:  (null)
number of ops:  28
compiled vars:  !0 = $i, !1 = $day, !2 = $next_day
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 1
          1      > JMP                                                      ->25
    4     2    >   IS_SMALLER                                               !0, 10
          3      > JMPZ                                                     ~4, ->16
    5     4    >   CONCAT                                           ~5      '0', !0
          5        ASSIGN                                                   !1, ~5
    6     6        ADD                                              ~7      !0, 1
          7        IS_SMALLER                                               ~7, 10
          8      > JMPZ                                                     ~8, ->13
    7     9    >   ADD                                              ~9      !0, 1
         10        CONCAT                                           ~10     '0', ~9
         11        ASSIGN                                                   !2, ~10
         12      > JMP                                                      ->15
    9    13    >   ADD                                              ~12     !0, 1
         14        ASSIGN                                                   !2, ~12
         15    > > JMP                                                      ->19
   12    16    >   ASSIGN                                                   !1, !0
   13    17        ADD                                              ~15     !0, 1
         18        ASSIGN                                                   !2, ~15
   15    19    >   ROPE_INIT                                     3  ~18     !1
         20        ROPE_ADD                                      1  ~18     ~18, '+'
         21        ROPE_END                                      2  ~17     ~18, !2
         22        CONCAT                                           ~20     ~17, '%0A'
         23        ECHO                                                     ~20
    2    24        PRE_INC                                                  !0
         25    >   IS_SMALLER_OR_EQUAL                                      !0, 31
         26      > JMPNZ                                                    ~22, ->2
   16    27    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.24 ms | 1395 KiB | 13 Q