3v4l.org

run code in 300+ PHP versions simultaneously
<?php $consts = get_defined_constants(); $consts = array_keys($consts); usort($consts, function($a, $b) { return strlen($b) <=> strlen($a); }); foreach($consts as $const){ echo strlen($const).": ".$const."\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 13, Position 2 = 20
Branch analysis from position: 13
2 jumps found. (Code = 78) Position 1 = 14, Position 2 = 20
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 13
Branch analysis from position: 13
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/PLYAP
function name:  (null)
number of ops:  22
compiled vars:  !0 = $consts, !1 = $const
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'get_defined_constants'
          1        DO_ICALL                                         $2      
          2        ASSIGN                                                   !0, $2
    3     3        INIT_FCALL                                               'array_keys'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $4      
          6        ASSIGN                                                   !0, $4
    5     7        INIT_FCALL                                               'usort'
          8        SEND_REF                                                 !0
          9        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FPLYAP%3A5%240'
    7    10        SEND_VAL                                                 ~6
         11        DO_ICALL                                                 
    9    12      > FE_RESET_R                                       $8      !0, ->20
         13    > > FE_FETCH_R                                               $8, !1, ->20
   10    14    >   STRLEN                                           ~9      !1
         15        CONCAT                                           ~10     ~9, '%3A+'
         16        CONCAT                                           ~11     ~10, !1
         17        CONCAT                                           ~12     ~11, '%0A'
         18        ECHO                                                     ~12
    9    19      > JMP                                                      ->13
         20    >   FE_FREE                                                  $8
   11    21      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FPLYAP%3A5%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/PLYAP
function name:  {closure}
number of ops:  7
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    6     2        STRLEN                                           ~2      !1
          3        STRLEN                                           ~3      !0
          4        SPACESHIP                                        ~4      ~2, ~3
          5      > RETURN                                                   ~4
    7     6*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FPLYAP%3A5%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.61 ms | 944 KiB | 20 Q