3v4l.org

run code in 300+ PHP versions simultaneously
<?php $strings = ['ES-3810/24MX', 'ES-3810/24MX35 123 TEST 34/TEST']; foreach ($strings as $string) { var_export( preg_match_all('/[a-z]+|\d+/i', $string, $m) ? $m[0] : [] ); echo "\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 18
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 18
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 13
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/Jq3Sk
function name:  (null)
number of ops:  20
compiled vars:  !0 = $strings, !1 = $string, !2 = $m
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1      > FE_RESET_R                                       $4      !0, ->18
          2    > > FE_FETCH_R                                               $4, !1, ->18
    6     3    >   INIT_FCALL                                               'var_export'
    7     4        INIT_FCALL                                               'preg_match_all'
          5        SEND_VAL                                                 '%2F%5Ba-z%5D%2B%7C%5Cd%2B%2Fi'
          6        SEND_VAR                                                 !1
          7        SEND_REF                                                 !2
          8        DO_ICALL                                         $5      
          9      > JMPZ                                                     $5, ->13
         10    >   FETCH_DIM_R                                      ~6      !2, 0
         11        QM_ASSIGN                                        ~7      ~6
         12      > JMP                                                      ->14
         13    >   QM_ASSIGN                                        ~7      <array>
         14    >   SEND_VAL                                                 ~7
    6    15        DO_ICALL                                                 
    9    16        ECHO                                                     '%0A'
    5    17      > JMP                                                      ->2
         18    >   FE_FREE                                                  $4
   10    19      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.04 ms | 1014 KiB | 15 Q