3v4l.org

run code in 300+ PHP versions simultaneously
<?php $pages = array('index', 'login', 'pricing', 'documentation', 'support', 'signup'); $cleanpage = "index0.html"; $similar = array(); $levenshtein = array(); $soundex = array(); foreach ($pages as $key => $page) { $similar[$page] = similar_text($cleanpage, $page); $levenshtein[$page] = levenshtein($cleanpage, $page); $soundex[$page] = abs(soundex($cleanpage) - soundex($page)); } print_r($similar); print_r($levenshtein); print_r($soundex); ?>

Abusive script

This script was stopped while abusing our resources

Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 33
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 33
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 33
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 33
filename:       /in/h7pmW
function name:  (null)
number of ops:  44
compiled vars:  !0 = $pages, !1 = $cleanpage, !2 = $similar, !3 = $levenshtein, !4 = $soundex, !5 = $page, !6 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN                                                   !1, 'index0.html'
    4     2        ASSIGN                                                   !2, <array>
    5     3        ASSIGN                                                   !3, <array>
    6     4        ASSIGN                                                   !4, <array>
    7     5      > FE_RESET_R                                       $12     !0, ->33
          6    > > FE_FETCH_R                                       ~13     $12, !5, ->33
          7    >   ASSIGN                                                   !6, ~13
    8     8        INIT_FCALL                                               'similar_text'
          9        SEND_VAR                                                 !1
         10        SEND_VAR                                                 !5
         11        DO_ICALL                                         $16     
         12        ASSIGN_DIM                                               !2, !5
         13        OP_DATA                                                  $16
    9    14        INIT_FCALL                                               'levenshtein'
         15        SEND_VAR                                                 !1
         16        SEND_VAR                                                 !5
         17        DO_ICALL                                         $18     
         18        ASSIGN_DIM                                               !3, !5
         19        OP_DATA                                                  $18
   10    20        INIT_FCALL                                               'abs'
         21        INIT_FCALL                                               'soundex'
         22        SEND_VAR                                                 !1
         23        DO_ICALL                                         $20     
         24        INIT_FCALL                                               'soundex'
         25        SEND_VAR                                                 !5
         26        DO_ICALL                                         $21     
         27        SUB                                              ~22     $20, $21
         28        SEND_VAL                                                 ~22
         29        DO_ICALL                                         $23     
         30        ASSIGN_DIM                                               !4, !5
         31        OP_DATA                                                  $23
    7    32      > JMP                                                      ->6
         33    >   FE_FREE                                                  $12
   13    34        INIT_FCALL                                               'print_r'
         35        SEND_VAR                                                 !2
         36        DO_ICALL                                                 
   14    37        INIT_FCALL                                               'print_r'
         38        SEND_VAR                                                 !3
         39        DO_ICALL                                                 
   15    40        INIT_FCALL                                               'print_r'
         41        SEND_VAR                                                 !4
         42        DO_ICALL                                                 
   16    43      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.23 ms | 1392 KiB | 23 Q