3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = [ [11, 22, 32, 44], [22, 33, 44, 45], [12, 24, 25, 31], [15, 16, 31, 41], [22, 33, 44, 45], [44, 22, 32, 11] ]; $set = []; foreach($arr as $curr_array){ sort($curr_array); $hash = implode("|",$curr_array); if(isset($set[$hash])) echo "Duplicate",PHP_EOL; else{ print_r($curr_array); $set[$hash] = true; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 23
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 23
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 17
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/EXXRu
function name:  (null)
number of ops:  25
compiled vars:  !0 = $arr, !1 = $set, !2 = $curr_array, !3 = $hash
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   13     1        ASSIGN                                                   !1, <array>
   14     2      > FE_RESET_R                                       $6      !0, ->23
          3    > > FE_FETCH_R                                               $6, !2, ->23
   15     4    >   INIT_FCALL                                               'sort'
          5        SEND_REF                                                 !2
          6        DO_ICALL                                                 
   16     7        INIT_FCALL                                               'implode'
          8        SEND_VAL                                                 '%7C'
          9        SEND_VAR                                                 !2
         10        DO_ICALL                                         $8      
         11        ASSIGN                                                   !3, $8
   17    12        ISSET_ISEMPTY_DIM_OBJ                         0          !1, !3
         13      > JMPZ                                                     ~10, ->17
         14    >   ECHO                                                     'Duplicate'
         15        ECHO                                                     '%0A'
         16      > JMP                                                      ->22
   19    17    >   INIT_FCALL                                               'print_r'
         18        SEND_VAR                                                 !2
         19        DO_ICALL                                                 
   20    20        ASSIGN_DIM                                               !1, !3
         21        OP_DATA                                                  <true>
   14    22    > > JMP                                                      ->3
         23    >   FE_FREE                                                  $6
   22    24      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.86 ms | 1001 KiB | 16 Q