3v4l.org

run code in 300+ PHP versions simultaneously
<?php function getNameFromNumber($num) { $numeric = $num % 26; $letter = chr(65 + $numeric); $num2 = intval($num / 26); if ($num2 > 0) { return getNameFromNumber($num2 - 1) . $letter; } else { return $letter; } } echo getNameFromNumber(100);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NpHXI
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL                                               'getnamefromnumber'
          1        SEND_VAL                                                 100
          2        DO_FCALL                                      0  $0      
          3        ECHO                                                     $0
          4      > RETURN                                                   1

Function getnamefromnumber:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 20
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NpHXI
function name:  getNameFromNumber
number of ops:  22
compiled vars:  !0 = $num, !1 = $numeric, !2 = $letter, !3 = $num2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    1     0  E >   RECV                                             !0      
    2     1        MOD                                              ~4      !0, 26
          2        ASSIGN                                                   !1, ~4
    3     3        INIT_FCALL                                               'chr'
          4        ADD                                              ~6      65, !1
          5        SEND_VAL                                                 ~6
          6        DO_ICALL                                         $7      
          7        ASSIGN                                                   !2, $7
    4     8        DIV                                              ~9      !0, 26
          9        CAST                                          4  ~10     ~9
         10        ASSIGN                                                   !3, ~10
    5    11        IS_SMALLER                                               0, !3
         12      > JMPZ                                                     ~12, ->20
    6    13    >   INIT_FCALL_BY_NAME                                       'getNameFromNumber'
         14        SUB                                              ~13     !3, 1
         15        SEND_VAL_EX                                              ~13
         16        DO_FCALL                                      0  $14     
         17        CONCAT                                           ~15     $14, !2
         18      > RETURN                                                   ~15
         19*       JMP                                                      ->21
    8    20    > > RETURN                                                   !2
   10    21*     > RETURN                                                   null

End of function getnamefromnumber

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.75 ms | 944 KiB | 17 Q