3v4l.org

run code in 300+ PHP versions simultaneously
<?php $result=range(1,5); $left=count($result); $rowLeft=5; $limit=0; $i=0; foreach($result as $row) { if($i==0) { $rowLeft--; $limit=ceil($left/$rowLeft); echo '<ul>'; } echo '<li>'.$row.'</li>'; $i++; $left--; if($i>=$limit) { echo '</ul>'; $i=0; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 11, Position 2 = 31
Branch analysis from position: 11
2 jumps found. (Code = 78) Position 1 = 12, Position 2 = 31
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 21
Branch analysis from position: 14
2 jumps found. (Code = 43) Position 1 = 28, Position 2 = 30
Branch analysis from position: 28
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
Branch analysis from position: 30
Branch analysis from position: 21
Branch analysis from position: 31
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 31
filename:       /in/qLnr9
function name:  (null)
number of ops:  33
compiled vars:  !0 = $result, !1 = $left, !2 = $rowLeft, !3 = $limit, !4 = $i, !5 = $row
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'range'
          1        SEND_VAL                                                 1
          2        SEND_VAL                                                 5
          3        DO_ICALL                                         $6      
          4        ASSIGN                                                   !0, $6
    3     5        COUNT                                            ~8      !0
          6        ASSIGN                                                   !1, ~8
    4     7        ASSIGN                                                   !2, 5
    5     8        ASSIGN                                                   !3, 0
    6     9        ASSIGN                                                   !4, 0
    7    10      > FE_RESET_R                                       $13     !0, ->31
         11    > > FE_FETCH_R                                               $13, !5, ->31
    9    12    >   IS_EQUAL                                                 !4, 0
         13      > JMPZ                                                     ~14, ->21
   11    14    >   PRE_DEC                                                  !2
   12    15        INIT_FCALL                                               'ceil'
         16        DIV                                              ~16     !1, !2
         17        SEND_VAL                                                 ~16
         18        DO_ICALL                                         $17     
         19        ASSIGN                                                   !3, $17
   13    20        ECHO                                                     '%3Cul%3E'
   15    21    >   CONCAT                                           ~19     '%3Cli%3E', !5
         22        CONCAT                                           ~20     ~19, '%3C%2Fli%3E'
         23        ECHO                                                     ~20
   16    24        PRE_INC                                                  !4
   17    25        PRE_DEC                                                  !1
   18    26        IS_SMALLER_OR_EQUAL                                      !3, !4
         27      > JMPZ                                                     ~23, ->30
   20    28    >   ECHO                                                     '%3C%2Ful%3E'
   21    29        ASSIGN                                                   !4, 0
    7    30    > > JMP                                                      ->11
         31    >   FE_FREE                                                  $13
   23    32      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.52 ms | 1396 KiB | 17 Q