3v4l.org

run code in 500+ 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:  11
compiled vars:  !0 = $camelCase
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                       !0, 'USADollarSymbol'
    3     1        INIT_FCALL                                                   'strtolower'
    7     2        INIT_FCALL                                                   'lcfirst'
          3        SEND_VAR                                                     !0
          4        DO_ICALL                                             $2      
    4     5        FRAMELESS_ICALL_3                preg_replace        ~3      <array>, <array>
    7     6        OP_DATA                                                      $2
          7        SEND_VAL                                                     ~3
    3     8        DO_ICALL                                             $4      
    7     9        ECHO                                                         $4
    9    10      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
159.67 ms | 2105 KiB | 15 Q