3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = 0; for ($i = 0; $i < 100; $i++){ if (rand(0, 100) > 49) $x++; } echo ($x);
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 = 13, Position 2 = 3
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 10
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 13, Position 2 = 3
Branch analysis from position: 13
Branch analysis from position: 3
Branch analysis from position: 10
filename:       /in/1aNfO
function name:  (null)
number of ops:  15
compiled vars:  !0 = $x, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 0
    3     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->11
    4     3    >   INIT_FCALL                                               'rand'
          4        SEND_VAL                                                 0
          5        SEND_VAL                                                 100
          6        DO_ICALL                                         $4      
          7        IS_SMALLER                                               49, $4
          8      > JMPZ                                                     ~5, ->10
          9    >   PRE_INC                                                  !0
    3    10    >   PRE_INC                                                  !1
         11    >   IS_SMALLER                                               !1, 100
         12      > JMPNZ                                                    ~8, ->3
    6    13    >   ECHO                                                     !0
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
136.33 ms | 1395 KiB | 15 Q