3v4l.org

run code in 300+ PHP versions simultaneously
<?php $kalimat_dasar = "maaf, saya tiba-tiba harus pulang."; // handle tanda baca = ',','.','!','?' $regex_tanda_baca = '/[,\.]/'; $regex_pemisah = '#$1'; $kalimat_lv1 = preg_replace($regex_tanda_baca , $regex_pemisah , $kalimat_dasar); print_r($kalimat_lv1);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/0ARLm
function name:  (null)
number of ops:  13
compiled vars:  !0 = $kalimat_dasar, !1 = $regex_tanda_baca, !2 = $regex_pemisah, !3 = $kalimat_lv1
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'maaf%2C+saya+tiba-tiba+harus+pulang.'
    6     1        ASSIGN                                                   !1, '%2F%5B%2C%5C.%5D%2F'
    7     2        ASSIGN                                                   !2, '%23%241'
    8     3        INIT_FCALL                                               'preg_replace'
          4        SEND_VAR                                                 !1
          5        SEND_VAR                                                 !2
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $7      
          8        ASSIGN                                                   !3, $7
   11     9        INIT_FCALL                                               'print_r'
         10        SEND_VAR                                                 !3
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.48 ms | 1394 KiB | 17 Q