3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a='assert'; $b='php_uname'; ; function nonalpha($string) { $str = ''; $cons = array('a' => '@ !', 'b' => '< ^', 'c' => '< _', 'd' => '? [', 'e' => '; ^', 'f' => '] ;', 'g' => ': ]', 'h' => '@ (', 'i' => ') @', 'j' => '* @', 'k' => '@ +', 'l' => ', @', 'm' => '- @', 'n' => '@ .', 'o' => '/ @', 'p' => '- ]', 'q' => '_ .', 'r' => '_ -', 's' => '- ^', 't' => '+ _', 'u' => '+ ^', 'v' => '] +', 'w' => '_ (', 'x' => '^ &', 'y' => '_ &', 'z' => '[ !', '_' => '! ~', 'A' => '{ :', 'B' => '? }', 'C' => '> }', 'D' => '` $', 'E' => '` %', 'F' => '& `', 'G' => '| ;', 'H' => '( `', 'I' => '` )', 'J' => '` J', 'K' => '` +', 'L' => '` ,', 'M' => '` -', 'N' => '` .', 'O' => '/ `', 'P' => '| ,', 'Q' => '| -', 'R' => '. |', 'S' => '| /', 'T' => '( |', 'U' => '| )', 'V' => '* |', 'W' => '* }', 'X' => '# {', 'Y' => '} $', 'Z' => '! {'); $cons_num = array('1' => "(('-'^'|')^'`')", '2' => "((','^'~')^'`')", '3' => "(('-'^'`')^'~')", '4' => "(('*'^'`')^'~')", '5' => "(('+'^'`')^'~')", '6' => "(('('^'`')^'~')", '7' => "((')'^'`')^'~')", '8' => "((':'^'|')^'~')", '9' => "((';'^'|')^'~')", '0' => "(('.'^'`')^'~')"); foreach(str_split($string) as $char) { if (!is_numeric($char)) { $bits = explode(' ', $cons[$char]); $str.= "('$bits[0]'^'$bits[1]')."; } else { $str.= "{$cons_num[$char]}."; } } return rtrim($str, '.'); } print(nonalpha($a).PHP_EOL); print(nonalpha($b).PHP_EOL);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rdeXH
function name:  (null)
number of ops:  13
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'assert'
    3     1        ASSIGN                                                   !1, 'php_uname'
   19     2        INIT_FCALL                                               'nonalpha'
          3        SEND_VAR                                                 !0
          4        DO_FCALL                                      0  $4      
          5        CONCAT                                           ~5      $4, '%0A'
          6        ECHO                                                     ~5
   20     7        INIT_FCALL                                               'nonalpha'
          8        SEND_VAR                                                 !1
          9        DO_FCALL                                      0  $6      
         10        CONCAT                                           ~7      $6, '%0A'
         11        ECHO                                                     ~7
         12      > RETURN                                                   1

Function nonalpha:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 34
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 34
Branch analysis from position: 9
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 29
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 33
Branch analysis from position: 33
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 29
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 34
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 34
filename:       /in/rdeXH
function name:  nonalpha
number of ops:  41
compiled vars:  !0 = $string, !1 = $str, !2 = $cons, !3 = $cons_num, !4 = $char, !5 = $bits
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    6     1        ASSIGN                                                   !1, ''
    7     2        ASSIGN                                                   !2, <array>
    8     3        ASSIGN                                                   !3, <array>
    9     4        INIT_FCALL                                               'str_split'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $9      
          7      > FE_RESET_R                                       $10     $9, ->34
          8    > > FE_FETCH_R                                               $10, !4, ->34
   10     9    >   INIT_FCALL                                               'is_numeric'
         10        SEND_VAR                                                 !4
         11        DO_ICALL                                         $11     
         12        BOOL_NOT                                         ~12     $11
         13      > JMPZ                                                     ~12, ->29
   11    14    >   INIT_FCALL                                               'explode'
         15        SEND_VAL                                                 '+'
         16        FETCH_DIM_R                                      ~13     !2, !4
         17        SEND_VAL                                                 ~13
         18        DO_ICALL                                         $14     
         19        ASSIGN                                                   !5, $14
   12    20        ROPE_INIT                                     5  ~19     '%28%27'
         21        FETCH_DIM_R                                      ~16     !5, 0
         22        ROPE_ADD                                      1  ~19     ~19, ~16
         23        ROPE_ADD                                      2  ~19     ~19, '%27%5E%27'
         24        FETCH_DIM_R                                      ~17     !5, 1
         25        ROPE_ADD                                      3  ~19     ~19, ~17
         26        ROPE_END                                      4  ~18     ~19, '%27%29.'
         27        ASSIGN_OP                                     8          !1, ~18
         28      > JMP                                                      ->33
   14    29    >   FETCH_DIM_R                                      ~23     !3, !4
         30        NOP                                                      
         31        FAST_CONCAT                                      ~24     ~23, '.'
         32        ASSIGN_OP                                     8          !1, ~24
    9    33    > > JMP                                                      ->8
         34    >   FE_FREE                                                  $10
   17    35        INIT_FCALL                                               'rtrim'
         36        SEND_VAR                                                 !1
         37        SEND_VAL                                                 '.'
         38        DO_ICALL                                         $26     
         39      > RETURN                                                   $26
   18    40*     > RETURN                                                   null

End of function nonalpha

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.19 ms | 1394 KiB | 23 Q