3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(-1); abstract class AbstractWorker{ public $rank; public $isBoss; public $count; public $coffee; public $salary; public $pages; public function __construct($count, $rank, $isBoss) { $this->rank = $rank; $this->count = $count; $this->isBoss = $isBoss; } public function CalculationOfInformation($rank, $isBoss){ if ($this->rank == 2){ $this->salary = $this->salary * 1.25 * $this->count; } elseif ($this->rank == 3){ $this->salary = $this->salary * 1.5 * $this->count; } else { $this->salary = $this->salary * $this->count; } $this->coffee = $this->coffee * $this->count; $this->pages = $this->pages * $this->count; if ($this->isBoss == 1){ $this->salary *= 1.5; $this->coffee *= 2; $this->pages = 0; } } public function getInformation($value){ return $value; } } class Manager extends AbstractWorker{ public $coffee = 20; public $salary = 500; public $pages = 200; } class Marketer extends AbstractWorker{ public $coffee = 15; public $salary = 400; public $pages = 150; } class Engineer extends AbstractWorker{ public $coffee = 5; public $salary = 200; public $pages = 50; } class Analyst extends AbstractWorker{ public $coffee = 50; public $salary = 800; public $pages = 5; } class Department{ public $name; public $workers = array(); public function __construct($name) { $this->name = $name; } public function addWorkers(AbstractWorker $worker){ $worker->CalculationOfInformation($worker->rank, $worker->isBoss); $this->workers[] = $worker; } public function getInformarion (){ $informarion = array($this->name, 0, 0, 0, 0, 0); foreach ($this->workers as $worker) { $informarion[1] += $worker->getInformation($worker->count); $informarion[2] += $worker->getInformation($worker->salary); $informarion[3] += $worker->getInformation($worker->coffee); $informarion[4] += $worker->getInformation($worker->pages); } $informarion[5] = round($informarion[2] / $informarion[4], 1); return $informarion; } } class Company{ public $departments = array(); public function addDepartment(Department $department){ $this->departments[] = $department; } public function padLeft($value, $columnLength){ echo $value; echo str_repeat(" ", $columnLength - mb_strlen($value)); } public function calculatiotOfOutput(array $informarion){ $col1 = 15; $col2 = 10; $col3 = 10; $col4 = 8; $col5 = 8; $col6 = 15; echo $this->padLeft($informarion[0], $col1) . $this->padLeft($informarion[1], $col2) . $this->padLeft($informarion[2], $col3) . $this->padLeft($informarion[3], $col4) . $this->padLeft($informarion[4], $col5) . $this->padLeft($informarion[5], $col6) . "\n"; } public function printInformationOfDepartment(){ $columbNames = array("Департамент", "сотр.", "тугр.", "кофе", "стр.", "тугр./стр."); $this->calculatiotOfOutput($columbNames); echo "\n"; foreach ($this->departments as $department) { $informarion = $department->getInformarion(); $this->calculatiotOfOutput($informarion); } echo "\n"; $totalInformation = array("", 0, 0, 0, 0, 0); foreach ($this->departments as $department) { $informarion = $department->getInformarion(); $totalInformation[1] += $informarion[1]; $totalInformation[2] += $informarion[2]; $totalInformation[3] += $informarion[3]; $totalInformation[4] += $informarion[4]; $totalInformation[5] += $informarion[5]; } $totalInformation[0] = "Всего"; $averageInformation = array("", 0, 0, 0, 0, 0); for ($i = 1; $i < 6; $i++){ $averageInformation[$i] = $totalInformation[$i] / count($this->departments); } $averageInformation[0] = "Среднее"; $this->calculatiotOfOutput($averageInformation); $this->calculatiotOfOutput($totalInformation); } } $vektor = new Company; $vektor->addDepartment(new Department("Закупок")); $vektor->addDepartment(new Department("Продаж")); //$procurementDepartment = new Department("Закупок"); // $procurementDepartment->addWorkers(new Manager(14, 1, 0)); // $procurementDepartment->addWorkers(new Manager(10, 2, 0)); //$sellingDepartment = new Department("Продаж"); // $sellingDepartment->addWorkers(new Manager(5, 1, 0)); // $vektor->addDepartment($procurementDepartment); // $vektor->addDepartment($sellingDepartment); //$vektor->printInformationOfDepartment();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  (null)
number of ops:  19
compiled vars:  !0 = $vektor
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 -1
          2        DO_ICALL                                                 
  161     3        NEW                                              $2      'Company'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !0, $2
  163     6        INIT_METHOD_CALL                                         !0, 'addDepartment'
          7        NEW                                              $5      'Department'
          8        SEND_VAL_EX                                              '%D0%97%D0%B0%D0%BA%D1%83%D0%BF%D0%BE%D0%BA'
          9        DO_FCALL                                      0          
         10        SEND_VAR_NO_REF_EX                                       $5
         11        DO_FCALL                                      0          
  164    12        INIT_METHOD_CALL                                         !0, 'addDepartment'
         13        NEW                                              $8      'Department'
         14        SEND_VAL_EX                                              '%D0%9F%D1%80%D0%BE%D0%B4%D0%B0%D0%B6'
         15        DO_FCALL                                      0          
         16        SEND_VAR_NO_REF_EX                                       $8
         17        DO_FCALL                                      0          
  176    18      > RETURN                                                   1

Class AbstractWorker:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  __construct
number of ops:  10
compiled vars:  !0 = $count, !1 = $rank, !2 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   14     3        ASSIGN_OBJ                                               'rank'
          4        OP_DATA                                                  !1
   15     5        ASSIGN_OBJ                                               'count'
          6        OP_DATA                                                  !0
   16     7        ASSIGN_OBJ                                               'isBoss'
          8        OP_DATA                                                  !2
   17     9      > RETURN                                                   null

End of function __construct

Function calculationofinformation:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 46
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 22
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
Branch analysis from position: 46
filename:       /in/CU7ir
function name:  CalculationOfInformation
number of ops:  47
compiled vars:  !0 = $rank, !1 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   20     2        FETCH_OBJ_R                                      ~2      'rank'
          3        IS_EQUAL                                                 ~2, 2
          4      > JMPZ                                                     ~3, ->12
   21     5    >   FETCH_OBJ_R                                      ~5      'salary'
          6        MUL                                              ~6      ~5, 1.25
          7        FETCH_OBJ_R                                      ~7      'count'
          8        MUL                                              ~8      ~6, ~7
          9        ASSIGN_OBJ                                               'salary'
         10        OP_DATA                                                  ~8
         11      > JMP                                                      ->27
   22    12    >   FETCH_OBJ_R                                      ~9      'rank'
         13        IS_EQUAL                                                 ~9, 3
         14      > JMPZ                                                     ~10, ->22
   23    15    >   FETCH_OBJ_R                                      ~12     'salary'
         16        MUL                                              ~13     ~12, 1.5
         17        FETCH_OBJ_R                                      ~14     'count'
         18        MUL                                              ~15     ~13, ~14
         19        ASSIGN_OBJ                                               'salary'
         20        OP_DATA                                                  ~15
         21      > JMP                                                      ->27
   25    22    >   FETCH_OBJ_R                                      ~17     'salary'
         23        FETCH_OBJ_R                                      ~18     'count'
         24        MUL                                              ~19     ~17, ~18
         25        ASSIGN_OBJ                                               'salary'
         26        OP_DATA                                                  ~19
   28    27    >   FETCH_OBJ_R                                      ~21     'coffee'
         28        FETCH_OBJ_R                                      ~22     'count'
         29        MUL                                              ~23     ~21, ~22
         30        ASSIGN_OBJ                                               'coffee'
         31        OP_DATA                                                  ~23
   29    32        FETCH_OBJ_R                                      ~25     'pages'
         33        FETCH_OBJ_R                                      ~26     'count'
         34        MUL                                              ~27     ~25, ~26
         35        ASSIGN_OBJ                                               'pages'
         36        OP_DATA                                                  ~27
   31    37        FETCH_OBJ_R                                      ~28     'isBoss'
         38        IS_EQUAL                                                 ~28, 1
         39      > JMPZ                                                     ~29, ->46
   32    40    >   ASSIGN_OBJ_OP                                 3          'salary'
         41        OP_DATA                                                  1.5
   33    42        ASSIGN_OBJ_OP                                 3          'coffee'
         43        OP_DATA                                                  2
   34    44        ASSIGN_OBJ                                               'pages'
         45        OP_DATA                                                  0
   36    46    > > RETURN                                                   null

End of function calculationofinformation

Function getinformation:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  getInformation
number of ops:  3
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   38     0  E >   RECV                                             !0      
   39     1      > RETURN                                                   !0
   40     2*     > RETURN                                                   null

End of function getinformation

End of class AbstractWorker.

Class Manager:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  __construct
number of ops:  10
compiled vars:  !0 = $count, !1 = $rank, !2 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   14     3        ASSIGN_OBJ                                               'rank'
          4        OP_DATA                                                  !1
   15     5        ASSIGN_OBJ                                               'count'
          6        OP_DATA                                                  !0
   16     7        ASSIGN_OBJ                                               'isBoss'
          8        OP_DATA                                                  !2
   17     9      > RETURN                                                   null

End of function __construct

Function calculationofinformation:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 46
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 22
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
Branch analysis from position: 46
filename:       /in/CU7ir
function name:  CalculationOfInformation
number of ops:  47
compiled vars:  !0 = $rank, !1 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   20     2        FETCH_OBJ_R                                      ~2      'rank'
          3        IS_EQUAL                                                 ~2, 2
          4      > JMPZ                                                     ~3, ->12
   21     5    >   FETCH_OBJ_R                                      ~5      'salary'
          6        MUL                                              ~6      ~5, 1.25
          7        FETCH_OBJ_R                                      ~7      'count'
          8        MUL                                              ~8      ~6, ~7
          9        ASSIGN_OBJ                                               'salary'
         10        OP_DATA                                                  ~8
         11      > JMP                                                      ->27
   22    12    >   FETCH_OBJ_R                                      ~9      'rank'
         13        IS_EQUAL                                                 ~9, 3
         14      > JMPZ                                                     ~10, ->22
   23    15    >   FETCH_OBJ_R                                      ~12     'salary'
         16        MUL                                              ~13     ~12, 1.5
         17        FETCH_OBJ_R                                      ~14     'count'
         18        MUL                                              ~15     ~13, ~14
         19        ASSIGN_OBJ                                               'salary'
         20        OP_DATA                                                  ~15
         21      > JMP                                                      ->27
   25    22    >   FETCH_OBJ_R                                      ~17     'salary'
         23        FETCH_OBJ_R                                      ~18     'count'
         24        MUL                                              ~19     ~17, ~18
         25        ASSIGN_OBJ                                               'salary'
         26        OP_DATA                                                  ~19
   28    27    >   FETCH_OBJ_R                                      ~21     'coffee'
         28        FETCH_OBJ_R                                      ~22     'count'
         29        MUL                                              ~23     ~21, ~22
         30        ASSIGN_OBJ                                               'coffee'
         31        OP_DATA                                                  ~23
   29    32        FETCH_OBJ_R                                      ~25     'pages'
         33        FETCH_OBJ_R                                      ~26     'count'
         34        MUL                                              ~27     ~25, ~26
         35        ASSIGN_OBJ                                               'pages'
         36        OP_DATA                                                  ~27
   31    37        FETCH_OBJ_R                                      ~28     'isBoss'
         38        IS_EQUAL                                                 ~28, 1
         39      > JMPZ                                                     ~29, ->46
   32    40    >   ASSIGN_OBJ_OP                                 3          'salary'
         41        OP_DATA                                                  1.5
   33    42        ASSIGN_OBJ_OP                                 3          'coffee'
         43        OP_DATA                                                  2
   34    44        ASSIGN_OBJ                                               'pages'
         45        OP_DATA                                                  0
   36    46    > > RETURN                                                   null

End of function calculationofinformation

Function getinformation:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  getInformation
number of ops:  3
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   38     0  E >   RECV                                             !0      
   39     1      > RETURN                                                   !0
   40     2*     > RETURN                                                   null

End of function getinformation

End of class Manager.

Class Marketer:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  __construct
number of ops:  10
compiled vars:  !0 = $count, !1 = $rank, !2 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   14     3        ASSIGN_OBJ                                               'rank'
          4        OP_DATA                                                  !1
   15     5        ASSIGN_OBJ                                               'count'
          6        OP_DATA                                                  !0
   16     7        ASSIGN_OBJ                                               'isBoss'
          8        OP_DATA                                                  !2
   17     9      > RETURN                                                   null

End of function __construct

Function calculationofinformation:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 46
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 22
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
Branch analysis from position: 46
filename:       /in/CU7ir
function name:  CalculationOfInformation
number of ops:  47
compiled vars:  !0 = $rank, !1 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   20     2        FETCH_OBJ_R                                      ~2      'rank'
          3        IS_EQUAL                                                 ~2, 2
          4      > JMPZ                                                     ~3, ->12
   21     5    >   FETCH_OBJ_R                                      ~5      'salary'
          6        MUL                                              ~6      ~5, 1.25
          7        FETCH_OBJ_R                                      ~7      'count'
          8        MUL                                              ~8      ~6, ~7
          9        ASSIGN_OBJ                                               'salary'
         10        OP_DATA                                                  ~8
         11      > JMP                                                      ->27
   22    12    >   FETCH_OBJ_R                                      ~9      'rank'
         13        IS_EQUAL                                                 ~9, 3
         14      > JMPZ                                                     ~10, ->22
   23    15    >   FETCH_OBJ_R                                      ~12     'salary'
         16        MUL                                              ~13     ~12, 1.5
         17        FETCH_OBJ_R                                      ~14     'count'
         18        MUL                                              ~15     ~13, ~14
         19        ASSIGN_OBJ                                               'salary'
         20        OP_DATA                                                  ~15
         21      > JMP                                                      ->27
   25    22    >   FETCH_OBJ_R                                      ~17     'salary'
         23        FETCH_OBJ_R                                      ~18     'count'
         24        MUL                                              ~19     ~17, ~18
         25        ASSIGN_OBJ                                               'salary'
         26        OP_DATA                                                  ~19
   28    27    >   FETCH_OBJ_R                                      ~21     'coffee'
         28        FETCH_OBJ_R                                      ~22     'count'
         29        MUL                                              ~23     ~21, ~22
         30        ASSIGN_OBJ                                               'coffee'
         31        OP_DATA                                                  ~23
   29    32        FETCH_OBJ_R                                      ~25     'pages'
         33        FETCH_OBJ_R                                      ~26     'count'
         34        MUL                                              ~27     ~25, ~26
         35        ASSIGN_OBJ                                               'pages'
         36        OP_DATA                                                  ~27
   31    37        FETCH_OBJ_R                                      ~28     'isBoss'
         38        IS_EQUAL                                                 ~28, 1
         39      > JMPZ                                                     ~29, ->46
   32    40    >   ASSIGN_OBJ_OP                                 3          'salary'
         41        OP_DATA                                                  1.5
   33    42        ASSIGN_OBJ_OP                                 3          'coffee'
         43        OP_DATA                                                  2
   34    44        ASSIGN_OBJ                                               'pages'
         45        OP_DATA                                                  0
   36    46    > > RETURN                                                   null

End of function calculationofinformation

Function getinformation:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  getInformation
number of ops:  3
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   38     0  E >   RECV                                             !0      
   39     1      > RETURN                                                   !0
   40     2*     > RETURN                                                   null

End of function getinformation

End of class Marketer.

Class Engineer:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  __construct
number of ops:  10
compiled vars:  !0 = $count, !1 = $rank, !2 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   14     3        ASSIGN_OBJ                                               'rank'
          4        OP_DATA                                                  !1
   15     5        ASSIGN_OBJ                                               'count'
          6        OP_DATA                                                  !0
   16     7        ASSIGN_OBJ                                               'isBoss'
          8        OP_DATA                                                  !2
   17     9      > RETURN                                                   null

End of function __construct

Function calculationofinformation:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 46
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 22
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
Branch analysis from position: 46
filename:       /in/CU7ir
function name:  CalculationOfInformation
number of ops:  47
compiled vars:  !0 = $rank, !1 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   20     2        FETCH_OBJ_R                                      ~2      'rank'
          3        IS_EQUAL                                                 ~2, 2
          4      > JMPZ                                                     ~3, ->12
   21     5    >   FETCH_OBJ_R                                      ~5      'salary'
          6        MUL                                              ~6      ~5, 1.25
          7        FETCH_OBJ_R                                      ~7      'count'
          8        MUL                                              ~8      ~6, ~7
          9        ASSIGN_OBJ                                               'salary'
         10        OP_DATA                                                  ~8
         11      > JMP                                                      ->27
   22    12    >   FETCH_OBJ_R                                      ~9      'rank'
         13        IS_EQUAL                                                 ~9, 3
         14      > JMPZ                                                     ~10, ->22
   23    15    >   FETCH_OBJ_R                                      ~12     'salary'
         16        MUL                                              ~13     ~12, 1.5
         17        FETCH_OBJ_R                                      ~14     'count'
         18        MUL                                              ~15     ~13, ~14
         19        ASSIGN_OBJ                                               'salary'
         20        OP_DATA                                                  ~15
         21      > JMP                                                      ->27
   25    22    >   FETCH_OBJ_R                                      ~17     'salary'
         23        FETCH_OBJ_R                                      ~18     'count'
         24        MUL                                              ~19     ~17, ~18
         25        ASSIGN_OBJ                                               'salary'
         26        OP_DATA                                                  ~19
   28    27    >   FETCH_OBJ_R                                      ~21     'coffee'
         28        FETCH_OBJ_R                                      ~22     'count'
         29        MUL                                              ~23     ~21, ~22
         30        ASSIGN_OBJ                                               'coffee'
         31        OP_DATA                                                  ~23
   29    32        FETCH_OBJ_R                                      ~25     'pages'
         33        FETCH_OBJ_R                                      ~26     'count'
         34        MUL                                              ~27     ~25, ~26
         35        ASSIGN_OBJ                                               'pages'
         36        OP_DATA                                                  ~27
   31    37        FETCH_OBJ_R                                      ~28     'isBoss'
         38        IS_EQUAL                                                 ~28, 1
         39      > JMPZ                                                     ~29, ->46
   32    40    >   ASSIGN_OBJ_OP                                 3          'salary'
         41        OP_DATA                                                  1.5
   33    42        ASSIGN_OBJ_OP                                 3          'coffee'
         43        OP_DATA                                                  2
   34    44        ASSIGN_OBJ                                               'pages'
         45        OP_DATA                                                  0
   36    46    > > RETURN                                                   null

End of function calculationofinformation

Function getinformation:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  getInformation
number of ops:  3
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   38     0  E >   RECV                                             !0      
   39     1      > RETURN                                                   !0
   40     2*     > RETURN                                                   null

End of function getinformation

End of class Engineer.

Class Analyst:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CU7ir
function name:  __construct
number of ops:  10
compiled vars:  !0 = $count, !1 = $rank, !2 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   14     3        ASSIGN_OBJ                                               'rank'
          4        OP_DATA                                                  !1
   15     5        ASSIGN_OBJ                                               'count'
          6        OP_DATA                                                  !0
   16     7        ASSIGN_OBJ                                               'isBoss'
          8        OP_DATA                                                  !2
   17     9      > RETURN                                                   null

End of function __construct

Function calculationofinformation:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 46
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 22
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 27
Branch analysis from position: 27
Branch analysis from position: 22
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 46
Branch analysis from position: 40
Branch analysis from position: 46
filename:       /in/CU7ir
function name:  CalculationOfInformation
number of ops:  47
compiled vars:  !0 = $rank, !1 = $isBoss
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   20     2        FETCH_OBJ_R                                      ~2      'rank'
          3        IS_EQUAL                                                 ~2, 2
          4      > JMPZ                                                     ~3, ->12
   21     5    >   FETCH_OBJ_R                                      ~5   

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
173.51 ms | 1428 KiB | 15 Q