3v4l.org

run code in 300+ PHP versions simultaneously
<?php $search_tags = array( "happy", "summer", "beach", "glasses", "umbrella", "funny", "people", "music", "rap" ); $accounts = array( "account A", "account B", "account C" ); $accounts = new InfiniteIterator(new ArrayIterator($accounts)); foreach($search_tags as $tag) { echo ucfirst($accounts->current()), PHP_EOL; $accounts->next(); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 10, Position 2 = 21
Branch analysis from position: 10
2 jumps found. (Code = 78) Position 1 = 11, Position 2 = 21
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 21
filename:       /in/E4Ohp
function name:  (null)
number of ops:  23
compiled vars:  !0 = $search_tags, !1 = $accounts, !2 = $tag
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   14     1        ASSIGN                                                   !1, <array>
   20     2        NEW                                              $5      'InfiniteIterator'
          3        NEW                                              $6      'ArrayIterator'
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0          
          6        SEND_VAR_NO_REF_EX                                       $6
          7        DO_FCALL                                      0          
          8        ASSIGN                                                   !1, $5
   21     9      > FE_RESET_R                                       $10     !0, ->21
         10    > > FE_FETCH_R                                               $10, !2, ->21
   22    11    >   INIT_FCALL                                               'ucfirst'
         12        INIT_METHOD_CALL                                         !1, 'current'
         13        DO_FCALL                                      0  $11     
         14        SEND_VAR                                                 $11
         15        DO_ICALL                                         $12     
         16        ECHO                                                     $12
         17        ECHO                                                     '%0A'
   23    18        INIT_METHOD_CALL                                         !1, 'next'
         19        DO_FCALL                                      0          
   21    20      > JMP                                                      ->10
         21    >   FE_FREE                                                  $10
   24    22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.49 ms | 1399 KiB | 15 Q