3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.63 ms | 1395 KiB | 19 Q