3v4l.org

run code in 300+ PHP versions simultaneously
<?php define("EOL", "\n"); $max = 40; $start = ord("a"); $limit = ord("y"); $arr = array(); $arr[0] = chr($start); while($max--){ for($i = 0; $i <= (count($arr) - 1); $i++){ if(ord($arr[$i]) > $limit){ $arr[$i] = chr($start); if(isset($arr[$i + 1])){ $arr[$i+1] = chr(ord($arr[$i+1]) + 1); } else { $arr[$i+1] = chr($start); } } } var_dump(array_reverse($arr)); echo "[", implode("][", array_reverse($arr)), "]", EOL; $arr[0]++; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 74
Branch analysis from position: 74
2 jumps found. (Code = 44) Position 1 = 76, Position 2 = 14
Branch analysis from position: 76
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 50
Branch analysis from position: 50
2 jumps found. (Code = 44) Position 1 = 54, Position 2 = 16
Branch analysis from position: 54
2 jumps found. (Code = 44) Position 1 = 76, Position 2 = 14
Branch analysis from position: 76
Branch analysis from position: 14
Branch analysis from position: 16
2 jumps found. (Code = 43) Position 1 = 22, Position 2 = 49
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 30, Position 2 = 43
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 49
Branch analysis from position: 49
2 jumps found. (Code = 44) Position 1 = 54, Position 2 = 16
Branch analysis from position: 54
Branch analysis from position: 16
Branch analysis from position: 43
2 jumps found. (Code = 44) Position 1 = 54, Position 2 = 16
Branch analysis from position: 54
Branch analysis from position: 16
Branch analysis from position: 49
filename:       /in/kntb3
function name:  (null)
number of ops:  77
compiled vars:  !0 = $max, !1 = $start, !2 = $limit, !3 = $arr, !4 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'define'
          1        SEND_VAL                                                 'EOL'
          2        SEND_VAL                                                 '%0A'
          3        DO_ICALL                                                 
    5     4        ASSIGN                                                   !0, 40
    6     5        ASSIGN                                                   !1, 97
    7     6        ASSIGN                                                   !2, 121
    8     7        ASSIGN                                                   !3, <array>
    9     8        INIT_FCALL                                               'chr'
          9        SEND_VAR                                                 !1
         10        DO_ICALL                                         $11     
         11        ASSIGN_DIM                                               !3, 0
         12        OP_DATA                                                  $11
   11    13      > JMP                                                      ->74
   12    14    >   ASSIGN                                                   !4, 0
         15      > JMP                                                      ->50
   13    16    >   INIT_FCALL                                               'ord'
         17        FETCH_DIM_R                                      ~13     !3, !4
         18        SEND_VAL                                                 ~13
         19        DO_ICALL                                         $14     
         20        IS_SMALLER                                               !2, $14
         21      > JMPZ                                                     ~15, ->49
   14    22    >   INIT_FCALL                                               'chr'
         23        SEND_VAR                                                 !1
         24        DO_ICALL                                         $17     
         25        ASSIGN_DIM                                               !3, !4
         26        OP_DATA                                                  $17
   15    27        ADD                                              ~18     !4, 1
         28        ISSET_ISEMPTY_DIM_OBJ                         0          !3, ~18
         29      > JMPZ                                                     ~19, ->43
   16    30    >   ADD                                              ~20     !4, 1
         31        INIT_FCALL                                               'chr'
         32        INIT_FCALL                                               'ord'
         33        ADD                                              ~22     !4, 1
         34        FETCH_DIM_R                                      ~23     !3, ~22
         35        SEND_VAL                                                 ~23
         36        DO_ICALL                                         $24     
         37        ADD                                              ~25     $24, 1
         38        SEND_VAL                                                 ~25
         39        DO_ICALL                                         $26     
         40        ASSIGN_DIM                                               !3, ~20
         41        OP_DATA                                                  $26
         42      > JMP                                                      ->49
   18    43    >   ADD                                              ~27     !4, 1
         44        INIT_FCALL                                               'chr'
         45        SEND_VAR                                                 !1
         46        DO_ICALL                                         $29     
         47        ASSIGN_DIM                                               !3, ~27
         48        OP_DATA                                                  $29
   12    49    >   PRE_INC                                                  !4
         50    >   COUNT                                            ~31     !3
         51        SUB                                              ~32     ~31, 1
         52        IS_SMALLER_OR_EQUAL                                      !4, ~32
         53      > JMPNZ                                                    ~33, ->16
   22    54    >   INIT_FCALL                                               'var_dump'
         55        INIT_FCALL                                               'array_reverse'
         56        SEND_VAR                                                 !3
         57        DO_ICALL                                         $34     
         58        SEND_VAR                                                 $34
         59        DO_ICALL                                                 
   23    60        ECHO                                                     '%5B'
         61        INIT_FCALL                                               'implode'
         62        SEND_VAL                                                 '%5D%5B'
         63        INIT_FCALL                                               'array_reverse'
         64        SEND_VAR                                                 !3
         65        DO_ICALL                                         $36     
         66        SEND_VAR                                                 $36
         67        DO_ICALL                                         $37     
         68        ECHO                                                     $37
         69        ECHO                                                     '%5D'
         70        FETCH_CONSTANT                                   ~38     'EOL'
         71        ECHO                                                     ~38
   24    72        FETCH_DIM_RW                                     $39     !3, 0
         73        PRE_INC                                                  $39
   11    74    >   POST_DEC                                         ~41     !0
         75      > JMPNZ                                                    ~41, ->14
   25    76    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.76 ms | 1400 KiB | 25 Q