3v4l.org

run code in 300+ PHP versions simultaneously
<?php $vowels = array('a','e','i','o','u'); $other = array(); $prev = null; for ($x=0,$s=null,$s=null;$x<4;$x++) { if (in_array($prev, $other)) { $s .= array_rand($vowels); } else { $s .= array_rand($other); } $prev = $s; } echo $s;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 23
Branch analysis from position: 23
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 7
Branch analysis from position: 25
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 17
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 7
Branch analysis from position: 25
Branch analysis from position: 7
Branch analysis from position: 17
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 7
Branch analysis from position: 25
Branch analysis from position: 7
filename:       /in/sIBtM
function name:  (null)
number of ops:  27
compiled vars:  !0 = $vowels, !1 = $other, !2 = $prev, !3 = $x, !4 = $s
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN                                                   !1, <array>
    5     2        ASSIGN                                                   !2, null
    6     3        ASSIGN                                                   !3, 0
          4        ASSIGN                                                   !4, null
          5        ASSIGN                                                   !4, null
          6      > JMP                                                      ->23
    8     7    >   INIT_FCALL                                               'in_array'
          8        SEND_VAR                                                 !2
          9        SEND_VAR                                                 !1
         10        DO_ICALL                                         $11     
         11      > JMPZ                                                     $11, ->17
    9    12    >   INIT_FCALL                                               'array_rand'
         13        SEND_VAR                                                 !0
         14        DO_ICALL                                         $12     
         15        ASSIGN_OP                                     8          !4, $12
         16      > JMP                                                      ->21
   11    17    >   INIT_FCALL                                               'array_rand'
         18        SEND_VAR                                                 !1
         19        DO_ICALL                                         $14     
         20        ASSIGN_OP                                     8          !4, $14
   13    21    >   ASSIGN                                                   !2, !4
    6    22        PRE_INC                                                  !3
         23    >   IS_SMALLER                                               !3, 4
         24      > JMPNZ                                                    ~18, ->7
   17    25    >   ECHO                                                     !4
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.82 ms | 1396 KiB | 17 Q