3v4l.org

run code in 300+ PHP versions simultaneously
<?php //factorial.php $n = $argv[1]; $factorial = array_product(range(1, $n)); echo $factorial . "\n"; //direct output printf("%g\n", $factorial); //force scientific notation
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/UsE0h
function name:  (null)
number of ops:  17
compiled vars:  !0 = $n, !1 = $argv, !2 = $factorial
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   FETCH_DIM_R                                      ~3      !1, 1
          1        ASSIGN                                                   !0, ~3
    3     2        INIT_FCALL                                               'array_product'
          3        INIT_FCALL                                               'range'
          4        SEND_VAL                                                 1
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $5      
          7        SEND_VAR                                                 $5
          8        DO_ICALL                                         $6      
          9        ASSIGN                                                   !2, $6
    4    10        CONCAT                                           ~8      !2, '%0A'
         11        ECHO                                                     ~8
    5    12        INIT_FCALL                                               'printf'
         13        SEND_VAL                                                 '%25g%0A'
         14        SEND_VAR                                                 !2
         15        DO_ICALL                                                 
         16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.8 ms | 1394 KiB | 19 Q