3v4l.org

run code in 300+ PHP versions simultaneously
<?php $first = Array(607,608,609,610); $second = Array(607,608,609,800); $Fcount = count($first); $arr = array_merge($first, $second); $arrc= array_diff($arr, array_diff_assoc($arr, array_unique($arr))); foreach ($arrc as $value){ echo key($value); if($arrc >= $Fcount){ echo "first array". $value; }else{ echo "second array" . $value; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 22, Position 2 = 35
Branch analysis from position: 22
2 jumps found. (Code = 78) Position 1 = 23, Position 2 = 35
Branch analysis from position: 23
2 jumps found. (Code = 43) Position 1 = 29, Position 2 = 32
Branch analysis from position: 29
1 jumps found. (Code = 42) Position 1 = 34
Branch analysis from position: 34
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
Branch analysis from position: 32
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 35
filename:       /in/qq71i
function name:  (null)
number of ops:  37
compiled vars:  !0 = $first, !1 = $second, !2 = $Fcount, !3 = $arr, !4 = $arrc, !5 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, <array>
    5     2        COUNT                                            ~8      !0
          3        ASSIGN                                                   !2, ~8
    6     4        INIT_FCALL                                               'array_merge'
          5        SEND_VAR                                                 !0
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                         $10     
          8        ASSIGN                                                   !3, $10
    9     9        INIT_FCALL                                               'array_diff'
         10        SEND_VAR                                                 !3
         11        INIT_FCALL                                               'array_diff_assoc'
         12        SEND_VAR                                                 !3
         13        INIT_FCALL                                               'array_unique'
         14        SEND_VAR                                                 !3
         15        DO_ICALL                                         $12     
         16        SEND_VAR                                                 $12
         17        DO_ICALL                                         $13     
         18        SEND_VAR                                                 $13
         19        DO_ICALL                                         $14     
         20        ASSIGN                                                   !4, $14
   10    21      > FE_RESET_R                                       $16     !4, ->35
         22    > > FE_FETCH_R                                               $16, !5, ->35
   11    23    >   INIT_FCALL                                               'key'
         24        SEND_VAR                                                 !5
         25        DO_ICALL                                         $17     
         26        ECHO                                                     $17
   12    27        IS_SMALLER_OR_EQUAL                                      !2, !4
         28      > JMPZ                                                     ~18, ->32
   13    29    >   CONCAT                                           ~19     'first+array', !5
         30        ECHO                                                     ~19
         31      > JMP                                                      ->34
   15    32    >   CONCAT                                           ~20     'second+array', !5
         33        ECHO                                                     ~20
   10    34    > > JMP                                                      ->22
         35    >   FE_FREE                                                  $16
   17    36      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.03 ms | 1400 KiB | 23 Q