3v4l.org

run code in 300+ PHP versions simultaneously
<?php $camelCase = "USADollarSymbol"; echo strtolower( preg_replace( ["/([A-Z]+)/", "/_([A-Z]+)([A-Z][a-z])/"], ["_$1", "_$1_$2"], lcfirst($camelCase) ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/S7HB0
function name:  (null)
number of ops:  14
compiled vars:  !0 = $camelCase
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'USADollarSymbol'
    3     1        INIT_FCALL                                               'strtolower'
    4     2        INIT_FCALL                                               'preg_replace'
    5     3        SEND_VAL                                                 <array>
    6     4        SEND_VAL                                                 <array>
    7     5        INIT_FCALL                                               'lcfirst'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                         $3      
         10        SEND_VAR                                                 $3
         11        DO_ICALL                                         $4      
         12        ECHO                                                     $4
    9    13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.47 ms | 1394 KiB | 19 Q