3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = '42.842044272477885,24.00411307811737,42.8419420050838,24.00439202785492,42.8418318707778,24.004274010658264,42.84192627162353,24.003952145576477'; $arr = explode(",",$string); $i = 1; echo " var firCTB = ["; foreach($arr as $k => $v) { if($i==1) { echo "new google.maps.LatLng(".$v."," ; $i++; } else { $v = (($k+1) == count($arr))? $v.")": $v."),"; echo $v; $i = 1; } } echo "];"; ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 9, Position 2 = 31
Branch analysis from position: 9
2 jumps found. (Code = 78) Position 1 = 10, Position 2 = 31
Branch analysis from position: 10
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 30
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 18
2 jumps found. (Code = 43) Position 1 = 22, Position 2 = 25
Branch analysis from position: 22
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 31
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 31
filename:       /in/sTtSS
function name:  (null)
number of ops:  34
compiled vars:  !0 = $string, !1 = $arr, !2 = $i, !3 = $v, !4 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '42.842044272477885%2C24.00411307811737%2C42.8419420050838%2C24.00439202785492%2C42.8418318707778%2C24.004274010658264%2C42.84192627162353%2C24.003952145576477'
    3     1        INIT_FCALL                                               'explode'
          2        SEND_VAL                                                 '%2C'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $6      
          5        ASSIGN                                                   !1, $6
    4     6        ASSIGN                                                   !2, 1
    5     7        ECHO                                                     '++var+firCTB+%3D+%5B'
    6     8      > FE_RESET_R                                       $9      !1, ->31
          9    > > FE_FETCH_R                                       ~10     $9, !3, ->31
         10    >   ASSIGN                                                   !4, ~10
    8    11        IS_EQUAL                                                 !2, 1
         12      > JMPZ                                                     ~12, ->18
   10    13    >   CONCAT                                           ~13     'new+google.maps.LatLng%28', !3
         14        CONCAT                                           ~14     ~13, '%2C'
         15        ECHO                                                     ~14
   11    16        PRE_INC                                                  !2
         17      > JMP                                                      ->30
   15    18    >   ADD                                              ~16     !4, 1
         19        COUNT                                            ~17     !1
         20        IS_EQUAL                                                 ~16, ~17
         21      > JMPZ                                                     ~18, ->25
         22    >   CONCAT                                           ~19     !3, '%29'
         23        QM_ASSIGN                                        ~20     ~19
         24      > JMP                                                      ->27
         25    >   CONCAT                                           ~21     !3, '%29%2C'
         26        QM_ASSIGN                                        ~20     ~21
         27    >   ASSIGN                                                   !3, ~20
   16    28        ECHO                                                     !3
   17    29        ASSIGN                                                   !2, 1
    6    30    > > JMP                                                      ->9
         31    >   FE_FREE                                                  $9
   21    32        ECHO                                                     '%5D%3B'
   22    33      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.94 ms | 1400 KiB | 15 Q