3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = ['a','b','c','d','e']; echo implode(', ', array_slice($array, 0, -1)) . ' and ' . end($array);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Nchc1
function name:  (null)
number of ops:  17
compiled vars:  !0 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        INIT_FCALL                                               'implode'
          2        SEND_VAL                                                 '%2C+'
          3        INIT_FCALL                                               'array_slice'
          4        SEND_VAR                                                 !0
          5        SEND_VAL                                                 0
          6        SEND_VAL                                                 -1
          7        DO_ICALL                                         $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                         $3      
         10        CONCAT                                           ~4      $3, '+and+'
         11        INIT_FCALL                                               'end'
         12        SEND_REF                                                 !0
         13        DO_ICALL                                         $5      
         14        CONCAT                                           ~6      ~4, $5
         15        ECHO                                                     ~6
         16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
144.32 ms | 1460 KiB | 16 Q