3v4l.org

run code in 300+ PHP versions simultaneously
<?php $city = 'Charlotte'; echo [ 'Charlotte'=>183, 'Tampa'=>220, 'Pittsburgh'=>222, 'Los Angeles'=>475 ][$city] ?: 0; $city = 'Smallville'; echo @[ 'Charlotte'=>183, 'Tampa'=>220, 'Pittsburgh'=>222, 'Los Angeles'=>475 ][$city] ?: 0;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZSl0T
function name:  (null)
number of ops:  13
compiled vars:  !0 = $city
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'Charlotte'
    9     1        FETCH_DIM_R                                      ~2      <array>, !0
          2        JMP_SET                                          ~3      ~2, ->4
          3        QM_ASSIGN                                        ~3      0
          4        ECHO                                                     ~3
   11     5        ASSIGN                                                   !0, 'Smallville'
   14     6        BEGIN_SILENCE                                    ~5      
   18     7        FETCH_DIM_R                                      ~6      <array>, !0
          8        END_SILENCE                                              ~5
          9        JMP_SET                                          ~7      ~6, ->11
         10        QM_ASSIGN                                        ~7      0
         11        ECHO                                                     ~7
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.34 ms | 1384 KiB | 13 Q