3v4l.org

run code in 300+ PHP versions simultaneously
<?php $cars = array ( array("Volvo",22,18), array("BMW",15,13), array("Saab",5,2), array("Land Rover",17,15) ); // Produce: You should eat pizza, beer, and ice cream every day $phrase = "You should eat fruits, vegetables, and fiber every day."; $healthy = array("fruits", "vegetables", "fiber"); $yummy = array("pizza", "beer", "ice cream"); $newphrase = str_replace($healthy, $yummy, $phrase); $vevo = '02/09/2016'; echo $vevo; print_r($vevo); $date = new DateTime($vevo); echo $date->format('Y-m-d'); var_dump($cars); var_dump($newphrase); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kA0V6
function name:  (null)
number of ops:  30
compiled vars:  !0 = $cars, !1 = $phrase, !2 = $healthy, !3 = $yummy, !4 = $newphrase, !5 = $vevo, !6 = $date
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   11     1        ASSIGN                                                   !1, 'You+should+eat+fruits%2C+vegetables%2C+and+fiber+every+day.'
   12     2        ASSIGN                                                   !2, <array>
   13     3        ASSIGN                                                   !3, <array>
   15     4        INIT_FCALL                                               'str_replace'
          5        SEND_VAR                                                 !2
          6        SEND_VAR                                                 !3
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                         $11     
          9        ASSIGN                                                   !4, $11
   17    10        ASSIGN                                                   !5, '02%2F09%2F2016'
   18    11        ECHO                                                     !5
   19    12        INIT_FCALL                                               'print_r'
         13        SEND_VAR                                                 !5
         14        DO_ICALL                                                 
   20    15        NEW                                              $15     'DateTime'
         16        SEND_VAR_EX                                              !5
         17        DO_FCALL                                      0          
         18        ASSIGN                                                   !6, $15
   21    19        INIT_METHOD_CALL                                         !6, 'format'
         20        SEND_VAL_EX                                              'Y-m-d'
         21        DO_FCALL                                      0  $18     
         22        ECHO                                                     $18
   23    23        INIT_FCALL                                               'var_dump'
         24        SEND_VAR                                                 !0
         25        DO_ICALL                                                 
   24    26        INIT_FCALL                                               'var_dump'
         27        SEND_VAR                                                 !4
         28        DO_ICALL                                                 
   25    29      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.7 ms | 1395 KiB | 19 Q