3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "cao isso pala só temp que pala vai temp aparecer temp aqui cao"; $match=array(); $return = array_unique(explode(' ', $str)); $badWords = array('cao', 'pala', 'temp'); for ( $i = 0; $i < count($badWords); $i++ ) if( in_array( $badWords[$i] , $return ) ) echo 'Yes matched -> ' . $badWords[$i] . '\n';
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 24
Branch analysis from position: 24
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 13
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 23
Branch analysis from position: 19
2 jumps found. (Code = 44) Position 1 = 27, Position 2 = 13
Branch analysis from position: 27
Branch analysis from position: 13
Branch analysis from position: 23
filename:       /in/p30jU
function name:  (null)
number of ops:  28
compiled vars:  !0 = $str, !1 = $match, !2 = $return, !3 = $badWords, !4 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'cao+isso+pala+s%C3%B3+temp+que+pala+vai+temp+aparecer+temp+aqui+cao'
    3     1        ASSIGN                                                   !1, <array>
    5     2        INIT_FCALL                                               'array_unique'
          3        INIT_FCALL                                               'explode'
          4        SEND_VAL                                                 '+'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $7      
          7        SEND_VAR                                                 $7
          8        DO_ICALL                                         $8      
          9        ASSIGN                                                   !2, $8
    7    10        ASSIGN                                                   !3, <array>
    8    11        ASSIGN                                                   !4, 0
         12      > JMP                                                      ->24
    9    13    >   INIT_FCALL                                               'in_array'
         14        FETCH_DIM_R                                      ~12     !3, !4
         15        SEND_VAL                                                 ~12
         16        SEND_VAR                                                 !2
         17        DO_ICALL                                         $13     
         18      > JMPZ                                                     $13, ->23
   10    19    >   FETCH_DIM_R                                      ~14     !3, !4
         20        CONCAT                                           ~15     'Yes+matched+-%3E+', ~14
         21        CONCAT                                           ~16     ~15, '%5Cn'
         22        ECHO                                                     ~16
    8    23    >   PRE_INC                                                  !4
         24    >   COUNT                                            ~18     !3
         25        IS_SMALLER                                               !4, ~18
         26      > JMPNZ                                                    ~19, ->13
   10    27    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
218.75 ms | 1396 KiB | 19 Q