3v4l.org

run code in 300+ PHP versions simultaneously
<?php $search_array = array("https", "www", "stackoverflow", "com"); foreach($search_array as $i => $domain) { if ( $search_array[$i] == null || $domain == "http" && count($search_array) > 1 || $domain == "https" && count($search_array) > 1 || $domain == "www" && count($search_array) > 1 || $domain == "com" && count($search_array) > 1 ) unset($search_array[$i]); } die(print_r($search_array));
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 37
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 37
Branch analysis from position: 3
2 jumps found. (Code = 47) Position 1 = 7, Position 2 = 13
Branch analysis from position: 7
2 jumps found. (Code = 46) Position 1 = 9, Position 2 = 12
Branch analysis from position: 9
2 jumps found. (Code = 47) Position 1 = 14, Position 2 = 20
Branch analysis from position: 14
2 jumps found. (Code = 46) Position 1 = 16, Position 2 = 19
Branch analysis from position: 16
2 jumps found. (Code = 47) Position 1 = 21, Position 2 = 27
Branch analysis from position: 21
2 jumps found. (Code = 46) Position 1 = 23, Position 2 = 26
Branch analysis from position: 23
2 jumps found. (Code = 47) Position 1 = 28, Position 2 = 34
Branch analysis from position: 28
2 jumps found. (Code = 46) Position 1 = 30, Position 2 = 33
Branch analysis from position: 30
2 jumps found. (Code = 43) Position 1 = 35, Position 2 = 36
Branch analysis from position: 35
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 36
Branch analysis from position: 33
Branch analysis from position: 34
Branch analysis from position: 26
Branch analysis from position: 27
Branch analysis from position: 19
Branch analysis from position: 20
Branch analysis from position: 12
Branch analysis from position: 13
Branch analysis from position: 37
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 37
filename:       /in/41FYo
function name:  (null)
number of ops:  43
compiled vars:  !0 = $search_array, !1 = $domain, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1      > FE_RESET_R                                       $4      !0, ->37
          2    > > FE_FETCH_R                                       ~5      $4, !1, ->37
          3    >   ASSIGN                                                   !2, ~5
    7     4        FETCH_DIM_R                                      ~7      !0, !2
          5        IS_EQUAL                                         ~8      ~7, null
          6      > JMPNZ_EX                                         ~8      ~8, ->13
    8     7    >   IS_EQUAL                                         ~9      !1, 'http'
          8      > JMPZ_EX                                          ~9      ~9, ->12
          9    >   COUNT                                            ~10     !0
         10        IS_SMALLER                                       ~11     1, ~10
         11        BOOL                                             ~9      ~11
         12    >   BOOL                                             ~8      ~9
         13    > > JMPNZ_EX                                         ~8      ~8, ->20
    9    14    >   IS_EQUAL                                         ~12     !1, 'https'
         15      > JMPZ_EX                                          ~12     ~12, ->19
         16    >   COUNT                                            ~13     !0
         17        IS_SMALLER                                       ~14     1, ~13
         18        BOOL                                             ~12     ~14
         19    >   BOOL                                             ~8      ~12
         20    > > JMPNZ_EX                                         ~8      ~8, ->27
   10    21    >   IS_EQUAL                                         ~15     !1, 'www'
         22      > JMPZ_EX                                          ~15     ~15, ->26
         23    >   COUNT                                            ~16     !0
         24        IS_SMALLER                                       ~17     1, ~16
         25        BOOL                                             ~15     ~17
         26    >   BOOL                                             ~8      ~15
         27    > > JMPNZ_EX                                         ~8      ~8, ->34
   11    28    >   IS_EQUAL                                         ~18     !1, 'com'
         29      > JMPZ_EX                                          ~18     ~18, ->33
         30    >   COUNT                                            ~19     !0
         31        IS_SMALLER                                       ~20     1, ~19
         32        BOOL                                             ~18     ~20
         33    >   BOOL                                             ~8      ~18
         34    > > JMPZ                                                     ~8, ->36
   12    35    >   UNSET_DIM                                                !0, !2
    5    36    > > JMP                                                      ->2
         37    >   FE_FREE                                                  $4
   15    38        INIT_FCALL                                               'print_r'
         39        SEND_VAR                                                 !0
         40        DO_ICALL                                         $21     
         41      > EXIT                                                     $21
         42*     > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.52 ms | 1010 KiB | 14 Q