3v4l.org

run code in 500+ PHP versions simultaneously
<?php $number_1 = 0.01; $number_2 = 3.22321; $result = $number_1 * $number_2; $decimals = strlen($number_1) - strpos($number_1, ".")-1; Echo number_format($result, $decimals);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fGW5N
function name:  (null)
number of ops:  15
compiled vars:  !0 = $number_1, !1 = $number_2, !2 = $result, !3 = $decimals
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, 0.01
    4     1        ASSIGN                                                       !1, 3.22321
    5     2        MUL                                                  ~6      !0, !1
          3        ASSIGN                                                       !2, ~6
    7     4        STRLEN                                               ~8      !0
          5        FRAMELESS_ICALL_2                strpos              ~9      !0, '.'
          6        SUB                                                  ~10     ~8, ~9
          7        SUB                                                  ~11     ~10, 1
          8        ASSIGN                                                       !3, ~11
    9     9        INIT_FCALL                                                   'number_format'
         10        SEND_VAR                                                     !2
         11        SEND_VAR                                                     !3
         12        DO_ICALL                                             $13     
         13        ECHO                                                         $13
         14      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
156.77 ms | 2013 KiB | 14 Q