3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'H'; $decimalValues = array(); for ($i = 0; $i < strlen($string); $i++) { $decimalValues[] = ord($string[$i]); } echo '[' . implode(',', $decimalValues) . ']'; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 4
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 4
Branch analysis from position: 14
Branch analysis from position: 4
filename:       /in/V7TYG
function name:  (null)
number of ops:  22
compiled vars:  !0 = $string, !1 = $decimalValues, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'H'
    3     1        ASSIGN                                                   !1, <array>
    4     2        ASSIGN                                                   !2, 0
          3      > JMP                                                      ->11
    5     4    >   INIT_FCALL                                               'ord'
          5        FETCH_DIM_R                                      ~7      !0, !2
          6        SEND_VAL                                                 ~7
          7        DO_ICALL                                         $8      
          8        ASSIGN_DIM                                               !1
          9        OP_DATA                                                  $8
    4    10        PRE_INC                                                  !2
         11    >   STRLEN                                           ~10     !0
         12        IS_SMALLER                                               !2, ~10
         13      > JMPNZ                                                    ~11, ->4
    7    14    >   INIT_FCALL                                               'implode'
         15        SEND_VAL                                                 '%2C'
         16        SEND_VAR                                                 !1
         17        DO_ICALL                                         $12     
         18        CONCAT                                           ~13     '%5B', $12
         19        CONCAT                                           ~14     ~13, '%5D'
         20        ECHO                                                     ~14
    9    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.64 ms | 1395 KiB | 17 Q