3v4l.org

run code in 300+ PHP versions simultaneously
<?php $existing = array(1,2,3,4); $onForm = array(3,4,5,6); $removed = array_diff($existing,$onForm); $new = array_diff($onForm,$existing); echo 'existing'; print_r($existing); echo 'form'; print_r($onForm); echo 'removed'; print_r($removed); echo 'new'; print_r($new);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7t38b
function name:  (null)
number of ops:  29
compiled vars:  !0 = $existing, !1 = $onForm, !2 = $removed, !3 = $new
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, <array>
    5     1        ASSIGN                                                   !1, <array>
    7     2        INIT_FCALL                                               'array_diff'
          3        SEND_VAR                                                 !0
          4        SEND_VAR                                                 !1
          5        DO_ICALL                                         $6      
          6        ASSIGN                                                   !2, $6
    8     7        INIT_FCALL                                               'array_diff'
          8        SEND_VAR                                                 !1
          9        SEND_VAR                                                 !0
         10        DO_ICALL                                         $8      
         11        ASSIGN                                                   !3, $8
   10    12        ECHO                                                     'existing'
   11    13        INIT_FCALL                                               'print_r'
         14        SEND_VAR                                                 !0
         15        DO_ICALL                                                 
   13    16        ECHO                                                     'form'
   14    17        INIT_FCALL                                               'print_r'
         18        SEND_VAR                                                 !1
         19        DO_ICALL                                                 
   16    20        ECHO                                                     'removed'
   17    21        INIT_FCALL                                               'print_r'
         22        SEND_VAR                                                 !2
         23        DO_ICALL                                                 
   19    24        ECHO                                                     'new'
   20    25        INIT_FCALL                                               'print_r'
         26        SEND_VAR                                                 !3
         27        DO_ICALL                                                 
         28      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.14 ms | 1395 KiB | 17 Q