3v4l.org

run code in 500+ PHP versions simultaneously
<?php $str = "45.51088930166307,51,52.52216552154544,75"; $pos = strpos($str, ",", strpos($str, ",")+1); $arr = [substr($str, 0,$pos), substr($str,$pos+1)]; Var_dump($arr);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nnrlV
function name:  (null)
number of ops:  17
compiled vars:  !0 = $str, !1 = $pos, !2 = $arr
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, '45.51088930166307%2C51%2C52.52216552154544%2C75'
    4     1        FRAMELESS_ICALL_2                strpos              ~4      !0, '%2C'
          2        ADD                                                  ~5      ~4, 1
          3        FRAMELESS_ICALL_3                strpos              ~6      !0, '%2C'
          4        OP_DATA                                                      ~5
          5        ASSIGN                                                       !1, ~6
    5     6        FRAMELESS_ICALL_3                substr              ~8      !0, 0
          7        OP_DATA                                                      !1
          8        INIT_ARRAY                                           ~9      ~8
          9        ADD                                                  ~10     !1, 1
         10        FRAMELESS_ICALL_2                substr              ~11     !0, ~10
         11        ADD_ARRAY_ELEMENT                                    ~9      ~11
         12        ASSIGN                                                       !2, ~9
    6    13        INIT_FCALL                                                   'var_dump'
         14        SEND_VAR                                                     !2
         15        DO_ICALL                                                     
         16      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
158.58 ms | 2079 KiB | 14 Q