3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "1110001110000"; $arr = str_split($str); $nf = new NumberFormatter("en", NumberFormatter::SPELLOUT); Foreach($arr as $numb){ echo $nf->format($numb) . " "; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 12, Position 2 = 19
Branch analysis from position: 12
2 jumps found. (Code = 78) Position 1 = 13, Position 2 = 19
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
filename:       /in/nHX59
function name:  (null)
number of ops:  21
compiled vars:  !0 = $str, !1 = $arr, !2 = $nf, !3 = $numb
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '1110001110000'
    4     1        INIT_FCALL                                               'str_split'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $5      
          4        ASSIGN                                                   !1, $5
    6     5        NEW                                              $7      'NumberFormatter'
          6        SEND_VAL_EX                                              'en'
          7        FETCH_CLASS_CONSTANT                             ~8      'NumberFormatter', 'SPELLOUT'
          8        SEND_VAL_EX                                              ~8
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !2, $7
    7    11      > FE_RESET_R                                       $11     !1, ->19
         12    > > FE_FETCH_R                                               $11, !3, ->19
    8    13    >   INIT_METHOD_CALL                                         !2, 'format'
         14        SEND_VAR_EX                                              !3
         15        DO_FCALL                                      0  $12     
         16        CONCAT                                           ~13     $12, '+'
         17        ECHO                                                     ~13
    7    18      > JMP                                                      ->12
         19    >   FE_FREE                                                  $11
    9    20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.32 ms | 1010 KiB | 14 Q