3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array('one', 'two', 'three', 'four'); $i = sizeof($a); $j = 0; $array=""; for($j=0;$j<$i-1;$j++) { $array[] = $a[$j]." ".$a[$j+1]; } print_r($array);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 7
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 7
Branch analysis from position: 18
Branch analysis from position: 7
filename:       /in/skUv5
function name:  (null)
number of ops:  22
compiled vars:  !0 = $a, !1 = $i, !2 = $j, !3 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        COUNT                                            ~5      !0
          2        ASSIGN                                                   !1, ~5
    4     3        ASSIGN                                                   !2, 0
    5     4        ASSIGN                                                   !3, ''
    6     5        ASSIGN                                                   !2, 0
          6      > JMP                                                      ->15
    8     7    >   FETCH_DIM_R                                      ~11     !0, !2
          8        CONCAT                                           ~12     ~11, '+'
          9        ADD                                              ~13     !2, 1
         10        FETCH_DIM_R                                      ~14     !0, ~13
         11        CONCAT                                           ~15     ~12, ~14
         12        ASSIGN_DIM                                               !3
         13        OP_DATA                                                  ~15
    6    14        PRE_INC                                                  !2
         15    >   SUB                                              ~17     !1, 1
         16        IS_SMALLER                                               !2, ~17
         17      > JMPNZ                                                    ~18, ->7
   10    18    >   INIT_FCALL                                               'print_r'
         19        SEND_VAR                                                 !3
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.4 ms | 1395 KiB | 15 Q