3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "The date is : " . print_r(date_parse_from_format('Y-d-m H:i:s', '2014-02-05 5:22:35'), true); $date = strtotime(date('Y-d-m H:i:s', '2014-02-05 5:22:35')); $now = time(); echo round(abs($now - $date) / 60,2). " minutes ago";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eKas6
function name:  (null)
number of ops:  33
compiled vars:  !0 = $date, !1 = $now
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'print_r'
          1        INIT_FCALL                                               'date_parse_from_format'
          2        SEND_VAL                                                 'Y-d-m+H%3Ai%3As'
          3        SEND_VAL                                                 '2014-02-05+5%3A22%3A35'
          4        DO_ICALL                                         $2      
          5        SEND_VAR                                                 $2
          6        SEND_VAL                                                 <true>
          7        DO_ICALL                                         $3      
          8        CONCAT                                           ~4      'The+date+is+%3A+', $3
          9        ECHO                                                     ~4
    4    10        INIT_FCALL                                               'strtotime'
         11        INIT_FCALL                                               'date'
         12        SEND_VAL                                                 'Y-d-m+H%3Ai%3As'
         13        SEND_VAL                                                 '2014-02-05+5%3A22%3A35'
         14        DO_ICALL                                         $5      
         15        SEND_VAR                                                 $5
         16        DO_ICALL                                         $6      
         17        ASSIGN                                                   !0, $6
    6    18        INIT_FCALL                                               'time'
         19        DO_ICALL                                         $8      
         20        ASSIGN                                                   !1, $8
    8    21        INIT_FCALL                                               'round'
         22        INIT_FCALL                                               'abs'
         23        SUB                                              ~10     !1, !0
         24        SEND_VAL                                                 ~10
         25        DO_ICALL                                         $11     
         26        DIV                                              ~12     $11, 60
         27        SEND_VAL                                                 ~12
         28        SEND_VAL                                                 2
         29        DO_ICALL                                         $13     
         30        CONCAT                                           ~14     $13, '+minutes+ago'
         31        ECHO                                                     ~14
         32      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.03 ms | 1396 KiB | 27 Q