3v4l.org

run code in 300+ PHP versions simultaneously
<?php $address = '5e Dorpsstraat41-B'; $matchArr = array(); preg_match_all('/(\d+)/', $address, $matchArr); $houseNumber = array_pop($matchArr[0]); $houseNumberStartPos = strrpos($address, $houseNumber); $streetName = substr(0, $houseNumberStartPos, $address); print $streetName;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hfgh8
function name:  (null)
number of ops:  25
compiled vars:  !0 = $address, !1 = $matchArr, !2 = $houseNumber, !3 = $houseNumberStartPos, !4 = $streetName
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '5e+Dorpsstraat41-B'
    4     1        ASSIGN                                                   !1, <array>
    5     2        INIT_FCALL                                               'preg_match_all'
          3        SEND_VAL                                                 '%2F%28%5Cd%2B%29%2F'
          4        SEND_VAR                                                 !0
          5        SEND_REF                                                 !1
          6        DO_ICALL                                                 
    6     7        INIT_FCALL                                               'array_pop'
          8        FETCH_DIM_W                                      $8      !1, 0
          9        SEND_REF                                                 $8
         10        DO_ICALL                                         $9      
         11        ASSIGN                                                   !2, $9
    7    12        INIT_FCALL                                               'strrpos'
         13        SEND_VAR                                                 !0
         14        SEND_VAR                                                 !2
         15        DO_ICALL                                         $11     
         16        ASSIGN                                                   !3, $11
    8    17        INIT_FCALL                                               'substr'
         18        SEND_VAL                                                 0
         19        SEND_VAR                                                 !3
         20        SEND_VAR                                                 !0
         21        DO_ICALL                                         $13     
         22        ASSIGN                                                   !4, $13
    9    23        ECHO                                                     !4
         24      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.04 ms | 1395 KiB | 21 Q