3v4l.org

run code in 300+ PHP versions simultaneously
<?php $correctSentence = "The year stations are summer, winter, spring and fall."; $textSentence = "The year stations are four summer, winter and spring and summer."; $correctArray = str_word_count($correctSentence, 1); $textArray = str_word_count($textSentence, 1); var_export( array_merge( array_diff($textArray, $correctArray), array_keys(array_filter(array_count_values($textArray), fn($v) => $v > 1)) ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eGNVI
function name:  (null)
number of ops:  35
compiled vars:  !0 = $correctSentence, !1 = $textSentence, !2 = $correctArray, !3 = $textArray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'The+year+stations+are+summer%2C+winter%2C+spring+and+fall.'
    5     1        ASSIGN                                                   !1, 'The+year+stations+are+four+summer%2C+winter+and+spring+and+summer.'
    7     2        INIT_FCALL                                               'str_word_count'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 1
          5        DO_ICALL                                         $6      
          6        ASSIGN                                                   !2, $6
    8     7        INIT_FCALL                                               'str_word_count'
          8        SEND_VAR                                                 !1
          9        SEND_VAL                                                 1
         10        DO_ICALL                                         $8      
         11        ASSIGN                                                   !3, $8
   10    12        INIT_FCALL                                               'var_export'
   11    13        INIT_FCALL                                               'array_merge'
   12    14        INIT_FCALL                                               'array_diff'
         15        SEND_VAR                                                 !3
         16        SEND_VAR                                                 !2
         17        DO_ICALL                                         $10     
         18        SEND_VAR                                                 $10
   13    19        INIT_FCALL                                               'array_keys'
         20        INIT_FCALL                                               'array_filter'
         21        INIT_FCALL                                               'array_count_values'
         22        SEND_VAR                                                 !3
         23        DO_ICALL                                         $11     
         24        SEND_VAR                                                 $11
         25        DECLARE_LAMBDA_FUNCTION                          ~12     [0]
         26        SEND_VAL                                                 ~12
         27        DO_ICALL                                         $13     
         28        SEND_VAR                                                 $13
         29        DO_ICALL                                         $14     
         30        SEND_VAR                                                 $14
   11    31        DO_ICALL                                         $15     
   13    32        SEND_VAR                                                 $15
   10    33        DO_ICALL                                                 
   15    34      > RETURN                                                   1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eGNVI
function name:  {closure}
number of ops:  4
compiled vars:  !0 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        IS_SMALLER                                       ~1      1, !0
          2      > RETURN                                                   ~1
          3*     > RETURN                                                   null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
261.14 ms | 1025 KiB | 20 Q