3v4l.org

run code in 500+ PHP versions simultaneously
<?php error_reporting(-1); abstract class AbstractWorker{ public $rank; public $isBoss; public function __construct(int $rank, int $isBoss) { $this->rank = $rank; $this->isBoss = $isBoss; } public function getSalary(){ $salary = $this->getBasicSalary(); if ($this->rank == 2){ $salary *= 1.25; } elseif ($this->rank == 3){ $salary *= 1.5; } if ($this->isBoss == 1){ $salary *= 1.5; } return $salary; } public function getCoffee(){ $coffee = $this->getBasicCoffee(); if ($this->isBoss == 1){ $coffee *= 2; } return $coffee; } public function getPages(){ $pages = $this->getBasicPages(); if ($this->isBoss == 1){ $pages *= 0; } return $pages; } abstract function getBasicSalary(); abstract function getBasicCoffee(); abstract function getBasicPages(); } class Manager extends AbstractWorker{ public function getBasicSalary(){ return 500; } public function getBasicCoffee(){ return 20; } public function getBasicPages(){ return 200; } } class Marketer extends AbstractWorker{ public function getBasicSalary(){ return 400; } public function getBasicCoffee(){ return 15; } public function getBasicPages(){ return 150; } } class Engineer extends AbstractWorker{ public function getBasicSalary(){ return 200; } public function getBasicCoffee(){ return 5; } public function getBasicPages(){ return 50; } } class Analyst extends AbstractWorker{ public function getBasicSalary(){ return 800; } public function getBasicCoffee(){ return 50; } public function getBasicPages(){ return 5; } } class Department{ private $name; private $workers = array(); public function __construct(string $name) { $this->name = $name; } public function addWorker(AbstractWorker $worker){ $this->workers[] = $worker; } public function getNumberWorkers(){ return count($this->workers); } public function getDepartmentSalary(){ $totalSalary = 0; foreach ($this->workers as $worker) { $totalSalary += $worker->getSalary(); } return $totalSalary; } public function getDepartmentCoffee(){ $totalCoffee = 0; foreach ($this->workers as $worker) { $totalCoffee += $worker->getCoffee(); } return $totalCoffee; } public function getDepartmentPages(){ $totalPages = 0; foreach ($this->workers as $worker) { $totalPages += $worker->getPages(); } return $totalPages; } public function getDepartmentName(){ return $this->name; } public function addWorkersToDepartment(string $profession, int $count, int $rang, int $isBoss){ if ($profession == "Manager"){ for ($i = 0; $i < $count; $i++){ $this->addWorker(new Manager($rang, $isBoss)); } } elseif ($profession == "Marketer"){ for ($i = 0; $i < $count; $i++){ $this->addWorker(new Marketer($rang, $isBoss)); } } elseif ($profession == "Engineer"){ for ($i = 0; $i < $count; $i++){ $this->addWorker(new Engineer ($rang, $isBoss)); } } elseif ($profession == "Analyst"){ for ($i = 0; $i < $count; $i++){ $this->addWorker(new Analyst ($rang, $isBoss)); } } } } class Company{ private $departments = array(); public function addDepartment(Department $department){ $this->departments[] = $department; } public function getDepartments(){ return $this->departments; } public function getDepartmentCount(){ return count($this->departments); } } class Tabel{ private function padLeft($value, $columnLength){ echo $value; echo str_repeat(" ", $columnLength - mb_strlen($value)); } private function calculatiotOfOutput(array $informarion){ $col1 = 15; $col2 = 10; $col3 = 10; $col4 = 8; $col5 = 8; $col6 = 15; echo $this->padLeft($informarion["name"], $col1) . $this->padLeft($informarion["count"], $col2) . $this->padLeft($informarion["salary"], $col3) . $this->padLeft($informarion["coffee"], $col4) . $this->padLeft($informarion["pages"], $col5) . $this->padLeft($informarion["salaryDividePages"], $col6) . "\n"; } public function printTabel(Company $company){ $columnName = array("name" => "Департамент", "count" => "сотр.", "salary" => "тугр.", "coffee" => "кофе", "pages" => "стр.", "salaryDividePages" => "тугр./стр."); $this->calculatiotOfOutput($columnName); echo "\n"; $departmentInformation = array("name" => "", "count" => 0, "salary" => 0, "coffee" => 0, "pages" => 0, "salaryDividePages" => 0); foreach ($company->getDepartments() as $department) { $departmentInformation["name"] = $department->getDepartmentName(); $departmentInformation["count"] = $department->getNumberWorkers(); $departmentInformation["salary"] = $department->getDepartmentSalary(); $departmentInformation["coffee"] = $department->getDepartmentCoffee(); $departmentInformation["pages"] = $department->getDepartmentPages(); $departmentInformation["salaryDividePages"] = round($department->getDepartmentSalary() / $department->getDepartmentPages(), 1); $this->calculatiotOfOutput($departmentInformation); } echo "\n"; $totalInformation = array("name" => "Всего", "count" => 0, "salary" => 0, "coffee" => 0, "pages" => 0, "salaryDividePages" => 0); $totalInformation["name"] = "Всего"; foreach ($company->getDepartments() as $department) { $totalInformation["count"] += $department->getNumberWorkers(); $totalInformation["salary"] += $department->getDepartmentSalary(); $totalInformation["coffee"] += $department->getDepartmentCoffee(); $totalInformation["pages"] += $department->getDepartmentPages(); $totalInformation["salaryDividePages"] += round($department->getDepartmentSalary() / $department->getDepartmentPages(), 1); } $this->calculatiotOfOutput($totalInformation); $averageInformation = array("name" => "Среднее", "count" => round($totalInformation["count"] / $company->getDepartmentCount(), 1), "salary" => round($totalInformation["salary"] / $company->getDepartmentCount(), 1), "coffee" => round($totalInformation["coffee"] / $company->getDepartmentCount(), 1), "pages" => round($totalInformation["pages"] / $company->getDepartmentCount(), 1), "salaryDividePages" => round($totalInformation["salaryDividePages"] / $company->getDepartmentCount()), 1); $this->calculatiotOfOutput($averageInformation); } } $vektor = new Company; $tabel = new Tabel; $departmentOfProcurement = new Department("Закупок"); $departmentOfProcurement->addWorkersToDepartment("Manager", 9, 1, 0); $departmentOfProcurement->addWorkersToDepartment("Manager", 3, 2, 0); $departmentOfProcurement->addWorkersToDepartment("Manager", 2, 3, 0); $departmentOfProcurement->addWorkersToDepartment("Marketer", 2, 1, 0); $departmentOfProcurement->addWorkersToDepartment("Manager", 1, 2, 1); $departmentOfSales = new Department("Продаж"); $departmentOfSales->addWorkersToDepartment("Manager", 12, 1, 0); $departmentOfSales->addWorkersToDepartment("Marketer", 6, 1, 0); $departmentOfSales->addWorkersToDepartment("Analyst", 3, 1, 0); $departmentOfSales->addWorkersToDepartment("Analyst", 2, 2, 0); $departmentOfSales->addWorkersToDepartment("Marketer", 1, 2, 1); $departmentOfAdvertising = new Department("Рекламы"); $departmentOfAdvertising->addWorkersToDepartment("Marketer", 15, 1, 0); $departmentOfAdvertising->addWorkersToDepartment("Marketer", 10, 2, 0); $departmentOfAdvertising->addWorkersToDepartment("Manager", 8, 1, 0); $departmentOfAdvertising->addWorkersToDepartment("Engineer", 2, 1, 0); $departmentOfAdvertising->addWorkersToDepartment("Marketer", 1, 3, 1); $departmentOfLogistics = new Department("Логистики"); $departmentOfLogistics->addWorkersToDepartment("Manager", 13, 1, 0); $departmentOfLogistics->addWorkersToDepartment("Manager", 5, 2, 0); $departmentOfLogistics->addWorkersToDepartment("Engineer", 5, 1, 0); $departmentOfLogistics->addWorkersToDepartment("Manager", 1, 1, 1); $vektor->addDepartment($departmentOfProcurement); $vektor->addDepartment($departmentOfSales); $vektor->addDepartment($departmentOfAdvertising); $vektor->addDepartment($departmentOfLogistics); $tabel->printTabel($vektor);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  (null)
number of ops:  155
compiled vars:  !0 = $vektor, !1 = $tabel, !2 = $departmentOfProcurement, !3 = $departmentOfSales, !4 = $departmentOfAdvertising, !5 = $departmentOfLogistics
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   INIT_FCALL                                                   'error_reporting'
          1        SEND_VAL                                                     -1
          2        DO_ICALL                                                     
  286     3        NEW                                                  $7      'Company'
          4        DO_FCALL                                          0          
          5        ASSIGN                                                       !0, $7
  287     6        NEW                                                  $10     'Tabel'
          7        DO_FCALL                                          0          
          8        ASSIGN                                                       !1, $10
  289     9        NEW                                                  $13     'Department'
         10        SEND_VAL_EX                                                  '%D0%97%D0%B0%D0%BA%D1%83%D0%BF%D0%BE%D0%BA'
         11        DO_FCALL                                          0          
         12        ASSIGN                                                       !2, $13
  290    13        INIT_METHOD_CALL                                             !2, 'addWorkersToDepartment'
         14        SEND_VAL_EX                                                  'Manager'
         15        SEND_VAL_EX                                                  9
         16        SEND_VAL_EX                                                  1
         17        SEND_VAL_EX                                                  0
         18        DO_FCALL                                          0          
  291    19        INIT_METHOD_CALL                                             !2, 'addWorkersToDepartment'
         20        SEND_VAL_EX                                                  'Manager'
         21        SEND_VAL_EX                                                  3
         22        SEND_VAL_EX                                                  2
         23        SEND_VAL_EX                                                  0
         24        DO_FCALL                                          0          
  292    25        INIT_METHOD_CALL                                             !2, 'addWorkersToDepartment'
         26        SEND_VAL_EX                                                  'Manager'
         27        SEND_VAL_EX                                                  2
         28        SEND_VAL_EX                                                  3
         29        SEND_VAL_EX                                                  0
         30        DO_FCALL                                          0          
  293    31        INIT_METHOD_CALL                                             !2, 'addWorkersToDepartment'
         32        SEND_VAL_EX                                                  'Marketer'
         33        SEND_VAL_EX                                                  2
         34        SEND_VAL_EX                                                  1
         35        SEND_VAL_EX                                                  0
         36        DO_FCALL                                          0          
  294    37        INIT_METHOD_CALL                                             !2, 'addWorkersToDepartment'
         38        SEND_VAL_EX                                                  'Manager'
         39        SEND_VAL_EX                                                  1
         40        SEND_VAL_EX                                                  2
         41        SEND_VAL_EX                                                  1
         42        DO_FCALL                                          0          
  296    43        NEW                                                  $21     'Department'
         44        SEND_VAL_EX                                                  '%D0%9F%D1%80%D0%BE%D0%B4%D0%B0%D0%B6'
         45        DO_FCALL                                          0          
         46        ASSIGN                                                       !3, $21
  297    47        INIT_METHOD_CALL                                             !3, 'addWorkersToDepartment'
         48        SEND_VAL_EX                                                  'Manager'
         49        SEND_VAL_EX                                                  12
         50        SEND_VAL_EX                                                  1
         51        SEND_VAL_EX                                                  0
         52        DO_FCALL                                          0          
  298    53        INIT_METHOD_CALL                                             !3, 'addWorkersToDepartment'
         54        SEND_VAL_EX                                                  'Marketer'
         55        SEND_VAL_EX                                                  6
         56        SEND_VAL_EX                                                  1
         57        SEND_VAL_EX                                                  0
         58        DO_FCALL                                          0          
  299    59        INIT_METHOD_CALL                                             !3, 'addWorkersToDepartment'
         60        SEND_VAL_EX                                                  'Analyst'
         61        SEND_VAL_EX                                                  3
         62        SEND_VAL_EX                                                  1
         63        SEND_VAL_EX                                                  0
         64        DO_FCALL                                          0          
  300    65        INIT_METHOD_CALL                                             !3, 'addWorkersToDepartment'
         66        SEND_VAL_EX                                                  'Analyst'
         67        SEND_VAL_EX                                                  2
         68        SEND_VAL_EX                                                  2
         69        SEND_VAL_EX                                                  0
         70        DO_FCALL                                          0          
  301    71        INIT_METHOD_CALL                                             !3, 'addWorkersToDepartment'
         72        SEND_VAL_EX                                                  'Marketer'
         73        SEND_VAL_EX                                                  1
         74        SEND_VAL_EX                                                  2
         75        SEND_VAL_EX                                                  1
         76        DO_FCALL                                          0          
  303    77        NEW                                                  $29     'Department'
         78        SEND_VAL_EX                                                  '%D0%A0%D0%B5%D0%BA%D0%BB%D0%B0%D0%BC%D1%8B'
         79        DO_FCALL                                          0          
         80        ASSIGN                                                       !4, $29
  304    81        INIT_METHOD_CALL                                             !4, 'addWorkersToDepartment'
         82        SEND_VAL_EX                                                  'Marketer'
         83        SEND_VAL_EX                                                  15
         84        SEND_VAL_EX                                                  1
         85        SEND_VAL_EX                                                  0
         86        DO_FCALL                                          0          
  305    87        INIT_METHOD_CALL                                             !4, 'addWorkersToDepartment'
         88        SEND_VAL_EX                                                  'Marketer'
         89        SEND_VAL_EX                                                  10
         90        SEND_VAL_EX                                                  2
         91        SEND_VAL_EX                                                  0
         92        DO_FCALL                                          0          
  306    93        INIT_METHOD_CALL                                             !4, 'addWorkersToDepartment'
         94        SEND_VAL_EX                                                  'Manager'
         95        SEND_VAL_EX                                                  8
         96        SEND_VAL_EX                                                  1
         97        SEND_VAL_EX                                                  0
         98        DO_FCALL                                          0          
  307    99        INIT_METHOD_CALL                                             !4, 'addWorkersToDepartment'
        100        SEND_VAL_EX                                                  'Engineer'
        101        SEND_VAL_EX                                                  2
        102        SEND_VAL_EX                                                  1
        103        SEND_VAL_EX                                                  0
        104        DO_FCALL                                          0          
  308   105        INIT_METHOD_CALL                                             !4, 'addWorkersToDepartment'
        106        SEND_VAL_EX                                                  'Marketer'
        107        SEND_VAL_EX                                                  1
        108        SEND_VAL_EX                                                  3
        109        SEND_VAL_EX                                                  1
        110        DO_FCALL                                          0          
  310   111        NEW                                                  $37     'Department'
        112        SEND_VAL_EX                                                  '%D0%9B%D0%BE%D0%B3%D0%B8%D1%81%D1%82%D0%B8%D0%BA%D0%B8'
        113        DO_FCALL                                          0          
        114        ASSIGN                                                       !5, $37
  311   115        INIT_METHOD_CALL                                             !5, 'addWorkersToDepartment'
        116        SEND_VAL_EX                                                  'Manager'
        117        SEND_VAL_EX                                                  13
        118        SEND_VAL_EX                                                  1
        119        SEND_VAL_EX                                                  0
        120        DO_FCALL                                          0          
  312   121        INIT_METHOD_CALL                                             !5, 'addWorkersToDepartment'
        122        SEND_VAL_EX                                                  'Manager'
        123        SEND_VAL_EX                                                  5
        124        SEND_VAL_EX                                                  2
        125        SEND_VAL_EX                                                  0
        126        DO_FCALL                                          0          
  313   127        INIT_METHOD_CALL                                             !5, 'addWorkersToDepartment'
        128        SEND_VAL_EX                                                  'Engineer'
        129        SEND_VAL_EX                                                  5
        130        SEND_VAL_EX                                                  1
        131        SEND_VAL_EX                                                  0
        132        DO_FCALL                                          0          
  314   133        INIT_METHOD_CALL                                             !5, 'addWorkersToDepartment'
        134        SEND_VAL_EX                                                  'Manager'
        135        SEND_VAL_EX                                                  1
        136        SEND_VAL_EX                                                  1
        137        SEND_VAL_EX                                                  1
        138        DO_FCALL                                          0          
  316   139        INIT_METHOD_CALL                                             !0, 'addDepartment'
        140        SEND_VAR_EX                                                  !2
        141        DO_FCALL                                          0          
  317   142        INIT_METHOD_CALL                                             !0, 'addDepartment'
        143        SEND_VAR_EX                                                  !3
        144        DO_FCALL                                          0          
  318   145        INIT_METHOD_CALL                                             !0, 'addDepartment'
        146        SEND_VAR_EX                                                  !4
        147        DO_FCALL                                          0          
  319   148        INIT_METHOD_CALL                                             !0, 'addDepartment'
        149        SEND_VAR_EX                                                  !5
        150        DO_FCALL                                          0          
  321   151        INIT_METHOD_CALL                                             !1, 'printTabel'
        152        SEND_VAR_EX                                                  !0
        153        DO_FCALL                                          0          
        154      > RETURN                                                       1

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

End of function __construct

Function getsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
Branch analysis from position: 16
Branch analysis from position: 12
filename:       /in/aJdlK
function name:  getSalary
number of ops:  18
compiled vars:  !0 = $salary
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_METHOD_CALL                                             'getBasicSalary'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   18     3        FETCH_OBJ_R                                          ~3      'rank'
          4        IS_EQUAL                                                     ~3, 2
          5      > JMPZ                                                         ~4, ->8
   19     6    >   ASSIGN_OP                                         3          !0, 1.25
   18     7      > JMP                                                          ->12
   20     8    >   FETCH_OBJ_R                                          ~6      'rank'
          9        IS_EQUAL                                                     ~6, 3
         10      > JMPZ                                                         ~7, ->12
   21    11    >   ASSIGN_OP                                         3          !0, 1.5
   24    12    >   FETCH_OBJ_R                                          ~9      'isBoss'
         13        IS_EQUAL                                                     ~9, 1
         14      > JMPZ                                                         ~10, ->16
   25    15    >   ASSIGN_OP                                         3          !0, 1.5
   28    16    > > RETURN                                                       !0
   29    17*     > RETURN                                                       null

End of function getsalary

Function getcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getCoffee
number of ops:  9
compiled vars:  !0 = $coffee
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   32     0  E >   INIT_METHOD_CALL                                             'getBasicCoffee'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   34     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   35     6    >   ASSIGN_OP                                         3          !0, 2
   38     7    > > RETURN                                                       !0
   39     8*     > RETURN                                                       null

End of function getcoffee

Function getpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getPages
number of ops:  9
compiled vars:  !0 = $pages
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   42     0  E >   INIT_METHOD_CALL                                             'getBasicPages'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   44     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   45     6    >   ASSIGN_OP                                         3          !0, 0
   48     7    > > RETURN                                                       !0
   49     8*     > RETURN                                                       null

End of function getpages

Function getbasicsalary:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicSalary
number of ops:  1
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   51     0  E > > RETURN                                                       null

End of function getbasicsalary

Function getbasiccoffee:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicCoffee
number of ops:  1
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   52     0  E > > RETURN                                                       null

End of function getbasiccoffee

Function getbasicpages:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicPages
number of ops:  1
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   53     0  E > > RETURN                                                       null

End of function getbasicpages

End of class AbstractWorker.

Class Manager:
Function getbasicsalary:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicSalary
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   58     0  E > > RETURN                                                       500
   59     1*     > RETURN                                                       null

End of function getbasicsalary

Function getbasiccoffee:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicCoffee
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   62     0  E > > RETURN                                                       20
   63     1*     > RETURN                                                       null

End of function getbasiccoffee

Function getbasicpages:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicPages
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   66     0  E > > RETURN                                                       200
   67     1*     > RETURN                                                       null

End of function getbasicpages

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

End of function __construct

Function getsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
Branch analysis from position: 16
Branch analysis from position: 12
filename:       /in/aJdlK
function name:  getSalary
number of ops:  18
compiled vars:  !0 = $salary
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_METHOD_CALL                                             'getBasicSalary'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   18     3        FETCH_OBJ_R                                          ~3      'rank'
          4        IS_EQUAL                                                     ~3, 2
          5      > JMPZ                                                         ~4, ->8
   19     6    >   ASSIGN_OP                                         3          !0, 1.25
   18     7      > JMP                                                          ->12
   20     8    >   FETCH_OBJ_R                                          ~6      'rank'
          9        IS_EQUAL                                                     ~6, 3
         10      > JMPZ                                                         ~7, ->12
   21    11    >   ASSIGN_OP                                         3          !0, 1.5
   24    12    >   FETCH_OBJ_R                                          ~9      'isBoss'
         13        IS_EQUAL                                                     ~9, 1
         14      > JMPZ                                                         ~10, ->16
   25    15    >   ASSIGN_OP                                         3          !0, 1.5
   28    16    > > RETURN                                                       !0
   29    17*     > RETURN                                                       null

End of function getsalary

Function getcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getCoffee
number of ops:  9
compiled vars:  !0 = $coffee
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   32     0  E >   INIT_METHOD_CALL                                             'getBasicCoffee'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   34     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   35     6    >   ASSIGN_OP                                         3          !0, 2
   38     7    > > RETURN                                                       !0
   39     8*     > RETURN                                                       null

End of function getcoffee

Function getpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getPages
number of ops:  9
compiled vars:  !0 = $pages
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   42     0  E >   INIT_METHOD_CALL                                             'getBasicPages'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   44     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   45     6    >   ASSIGN_OP                                         3          !0, 0
   48     7    > > RETURN                                                       !0
   49     8*     > RETURN                                                       null

End of function getpages

End of class Manager.

Class Marketer:
Function getbasicsalary:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicSalary
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   72     0  E > > RETURN                                                       400
   73     1*     > RETURN                                                       null

End of function getbasicsalary

Function getbasiccoffee:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicCoffee
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   76     0  E > > RETURN                                                       15
   77     1*     > RETURN                                                       null

End of function getbasiccoffee

Function getbasicpages:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicPages
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   80     0  E > > RETURN                                                       150
   81     1*     > RETURN                                                       null

End of function getbasicpages

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

End of function __construct

Function getsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
Branch analysis from position: 16
Branch analysis from position: 12
filename:       /in/aJdlK
function name:  getSalary
number of ops:  18
compiled vars:  !0 = $salary
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_METHOD_CALL                                             'getBasicSalary'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   18     3        FETCH_OBJ_R                                          ~3      'rank'
          4        IS_EQUAL                                                     ~3, 2
          5      > JMPZ                                                         ~4, ->8
   19     6    >   ASSIGN_OP                                         3          !0, 1.25
   18     7      > JMP                                                          ->12
   20     8    >   FETCH_OBJ_R                                          ~6      'rank'
          9        IS_EQUAL                                                     ~6, 3
         10      > JMPZ                                                         ~7, ->12
   21    11    >   ASSIGN_OP                                         3          !0, 1.5
   24    12    >   FETCH_OBJ_R                                          ~9      'isBoss'
         13        IS_EQUAL                                                     ~9, 1
         14      > JMPZ                                                         ~10, ->16
   25    15    >   ASSIGN_OP                                         3          !0, 1.5
   28    16    > > RETURN                                                       !0
   29    17*     > RETURN                                                       null

End of function getsalary

Function getcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getCoffee
number of ops:  9
compiled vars:  !0 = $coffee
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   32     0  E >   INIT_METHOD_CALL                                             'getBasicCoffee'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   34     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   35     6    >   ASSIGN_OP                                         3          !0, 2
   38     7    > > RETURN                                                       !0
   39     8*     > RETURN                                                       null

End of function getcoffee

Function getpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getPages
number of ops:  9
compiled vars:  !0 = $pages
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   42     0  E >   INIT_METHOD_CALL                                             'getBasicPages'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   44     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   45     6    >   ASSIGN_OP                                         3          !0, 0
   48     7    > > RETURN                                                       !0
   49     8*     > RETURN                                                       null

End of function getpages

End of class Marketer.

Class Engineer:
Function getbasicsalary:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicSalary
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   86     0  E > > RETURN                                                       200
   87     1*     > RETURN                                                       null

End of function getbasicsalary

Function getbasiccoffee:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicCoffee
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   90     0  E > > RETURN                                                       5
   91     1*     > RETURN                                                       null

End of function getbasiccoffee

Function getbasicpages:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicPages
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   94     0  E > > RETURN                                                       50
   95     1*     > RETURN                                                       null

End of function getbasicpages

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

End of function __construct

Function getsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
Branch analysis from position: 16
Branch analysis from position: 12
filename:       /in/aJdlK
function name:  getSalary
number of ops:  18
compiled vars:  !0 = $salary
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_METHOD_CALL                                             'getBasicSalary'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   18     3        FETCH_OBJ_R                                          ~3      'rank'
          4        IS_EQUAL                                                     ~3, 2
          5      > JMPZ                                                         ~4, ->8
   19     6    >   ASSIGN_OP                                         3          !0, 1.25
   18     7      > JMP                                                          ->12
   20     8    >   FETCH_OBJ_R                                          ~6      'rank'
          9        IS_EQUAL                                                     ~6, 3
         10      > JMPZ                                                         ~7, ->12
   21    11    >   ASSIGN_OP                                         3          !0, 1.5
   24    12    >   FETCH_OBJ_R                                          ~9      'isBoss'
         13        IS_EQUAL                                                     ~9, 1
         14      > JMPZ                                                         ~10, ->16
   25    15    >   ASSIGN_OP                                         3          !0, 1.5
   28    16    > > RETURN                                                       !0
   29    17*     > RETURN                                                       null

End of function getsalary

Function getcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getCoffee
number of ops:  9
compiled vars:  !0 = $coffee
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   32     0  E >   INIT_METHOD_CALL                                             'getBasicCoffee'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   34     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   35     6    >   ASSIGN_OP                                         3          !0, 2
   38     7    > > RETURN                                                       !0
   39     8*     > RETURN                                                       null

End of function getcoffee

Function getpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getPages
number of ops:  9
compiled vars:  !0 = $pages
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   42     0  E >   INIT_METHOD_CALL                                             'getBasicPages'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   44     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   45     6    >   ASSIGN_OP                                         3          !0, 0
   48     7    > > RETURN                                                       !0
   49     8*     > RETURN                                                       null

End of function getpages

End of class Engineer.

Class Analyst:
Function getbasicsalary:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicSalary
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  100     0  E > > RETURN                                                       800
  101     1*     > RETURN                                                       null

End of function getbasicsalary

Function getbasiccoffee:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicCoffee
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  104     0  E > > RETURN                                                       50
  105     1*     > RETURN                                                       null

End of function getbasiccoffee

Function getbasicpages:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getBasicPages
number of ops:  2
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  108     0  E > > RETURN                                                       5
  109     1*     > RETURN                                                       null

End of function getbasicpages

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

End of function __construct

Function getsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 12
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
Branch analysis from position: 16
Branch analysis from position: 12
filename:       /in/aJdlK
function name:  getSalary
number of ops:  18
compiled vars:  !0 = $salary
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_METHOD_CALL                                             'getBasicSalary'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   18     3        FETCH_OBJ_R                                          ~3      'rank'
          4        IS_EQUAL                                                     ~3, 2
          5      > JMPZ                                                         ~4, ->8
   19     6    >   ASSIGN_OP                                         3          !0, 1.25
   18     7      > JMP                                                          ->12
   20     8    >   FETCH_OBJ_R                                          ~6      'rank'
          9        IS_EQUAL                                                     ~6, 3
         10      > JMPZ                                                         ~7, ->12
   21    11    >   ASSIGN_OP                                         3          !0, 1.5
   24    12    >   FETCH_OBJ_R                                          ~9      'isBoss'
         13        IS_EQUAL                                                     ~9, 1
         14      > JMPZ                                                         ~10, ->16
   25    15    >   ASSIGN_OP                                         3          !0, 1.5
   28    16    > > RETURN                                                       !0
   29    17*     > RETURN                                                       null

End of function getsalary

Function getcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getCoffee
number of ops:  9
compiled vars:  !0 = $coffee
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   32     0  E >   INIT_METHOD_CALL                                             'getBasicCoffee'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   34     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   35     6    >   ASSIGN_OP                                         3          !0, 2
   38     7    > > RETURN                                                       !0
   39     8*     > RETURN                                                       null

End of function getcoffee

Function getpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/aJdlK
function name:  getPages
number of ops:  9
compiled vars:  !0 = $pages
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   42     0  E >   INIT_METHOD_CALL                                             'getBasicPages'
          1        DO_FCALL                                          0  $1      
          2        ASSIGN                                                       !0, $1
   44     3        FETCH_OBJ_R                                          ~3      'isBoss'
          4        IS_EQUAL                                                     ~3, 1
          5      > JMPZ                                                         ~4, ->7
   45     6    >   ASSIGN_OP                                         3          !0, 0
   48     7    > > RETURN                                                       !0
   49     8*     > RETURN                                                       null

End of function getpages

End of class Analyst.

Class Department:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  __construct
number of ops:  4
compiled vars:  !0 = $name
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  116     0  E >   RECV                                                 !0      
  117     1        ASSIGN_OBJ                                                   'name'
          2        OP_DATA                                                      !0
  118     3      > RETURN                                                       null

End of function __construct

Function addworker:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  addWorker
number of ops:  5
compiled vars:  !0 = $worker
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  120     0  E >   RECV                                                 !0      
  122     1        FETCH_OBJ_W                                          $1      'workers'
          2        ASSIGN_DIM                                                   $1
          3        OP_DATA                                                      !0
  123     4      > RETURN                                                       null

End of function addworker

Function getnumberworkers:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getNumberWorkers
number of ops:  4
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  126     0  E >   FETCH_OBJ_R                                          ~0      'workers'
          1        COUNT                                                ~1      ~0
          2      > RETURN                                                       ~1
  127     3*     > RETURN                                                       null

End of function getnumberworkers

Function getdepartmentsalary:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 8
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/aJdlK
function name:  getDepartmentSalary
number of ops:  11
compiled vars:  !0 = $totalSalary, !1 = $worker
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  131     0  E >   ASSIGN                                                       !0, 0
  133     1        FETCH_OBJ_R                                          ~3      'workers'
          2      > FE_RESET_R                                           $4      ~3, ->8
          3    > > FE_FETCH_R                                                   $4, !1, ->8
  134     4    >   INIT_METHOD_CALL                                             !1, 'getSalary'
          5        DO_FCALL                                          0  $5      
          6        ASSIGN_OP                                         1          !0, $5
  133     7      > JMP                                                          ->3
          8    >   FE_FREE                                                      $4
  137     9      > RETURN                                                       !0
  138    10*     > RETURN                                                       null

End of function getdepartmentsalary

Function getdepartmentcoffee:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 8
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/aJdlK
function name:  getDepartmentCoffee
number of ops:  11
compiled vars:  !0 = $totalCoffee, !1 = $worker
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  141     0  E >   ASSIGN                                                       !0, 0
  143     1        FETCH_OBJ_R                                          ~3      'workers'
          2      > FE_RESET_R                                           $4      ~3, ->8
          3    > > FE_FETCH_R                                                   $4, !1, ->8
  144     4    >   INIT_METHOD_CALL                                             !1, 'getCoffee'
          5        DO_FCALL                                          0  $5      
          6        ASSIGN_OP                                         1          !0, $5
  143     7      > JMP                                                          ->3
          8    >   FE_FREE                                                      $4
  147     9      > RETURN                                                       !0
  148    10*     > RETURN                                                       null

End of function getdepartmentcoffee

Function getdepartmentpages:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 8
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/aJdlK
function name:  getDepartmentPages
number of ops:  11
compiled vars:  !0 = $totalPages, !1 = $worker
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  151     0  E >   ASSIGN                                                       !0, 0
  153     1        FETCH_OBJ_R                                          ~3      'workers'
          2      > FE_RESET_R                                           $4      ~3, ->8
          3    > > FE_FETCH_R                                                   $4, !1, ->8
  154     4    >   INIT_METHOD_CALL                                             !1, 'getPages'
          5        DO_FCALL                                          0  $5      
          6        ASSIGN_OP                                         1          !0, $5
  153     7      > JMP                                                          ->3
          8    >   FE_FREE                                                      $4
  157     9      > RETURN                                                       !0
  158    10*     > RETURN                                                       null

End of function getdepartmentpages

Function getdepartmentname:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getDepartmentName
number of ops:  3
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  161     0  E >   FETCH_OBJ_R                                          ~0      'name'
          1      > RETURN                                                       ~0
  162     2*     > RETURN                                                       null

End of function getdepartmentname

Function addworkerstodepartment:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 19
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 8
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 63
Branch analysis from position: 63
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 8
Branch analysis from position: 18
Branch analysis from position: 8
Branch analysis from position: 19
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 34
Branch analysis from position: 21
1 jumps found. (Code = 42) Position 1 = 31
Branch analysis from position: 31
2 jumps found. (Code = 44) Position 1 = 33, Position 2 = 23
Branch analysis from position: 33
1 jumps found. (Code = 42) Position 1 = 63
Branch analysis from position: 63
Branch analysis from position: 23
2 jumps found. (Code = 44) Position 1 = 33, Position 2 = 23
Branch analysis from position: 33
Branch analysis from position: 23
Branch analysis from position: 34
2 jumps found. (Code = 43) Position 1 = 36, Position 2 = 49
Branch analysis from position: 36
1 jumps found. (Code = 42) Position 1 = 46
Branch analysis from position: 46
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 38
Branch analysis from position: 48
1 jumps found. (Code = 42) Position 1 = 63
Branch analysis from position: 63
Branch analysis from position: 38
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 38
Branch analysis from position: 48
Branch analysis from position: 38
Branch analysis from position: 49
2 jumps found. (Code = 43) Position 1 = 51, Position 2 = 63
Branch analysis from position: 51
1 jumps found. (Code = 42) Position 1 = 61
Branch analysis from position: 61
2 jumps found. (Code = 44) Position 1 = 63, Position 2 = 53
Branch analysis from position: 63
Branch analysis from position: 53
2 jumps found. (Code = 44) Position 1 = 63, Position 2 = 53
Branch analysis from position: 63
Branch analysis from position: 53
Branch analysis from position: 63
filename:       /in/aJdlK
function name:  addWorkersToDepartment
number of ops:  64
compiled vars:  !0 = $profession, !1 = $count, !2 = $rang, !3 = $isBoss, !4 = $i
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  164     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
          2        RECV                                                 !2      
          3        RECV                                                 !3      
  166     4        IS_EQUAL                                                     !0, 'Manager'
          5      > JMPZ                                                         ~5, ->19
  167     6    >   ASSIGN                                                       !4, 0
          7      > JMP                                                          ->16
  168     8    >   INIT_METHOD_CALL                                             'addWorker'
          9        NEW                                                  $7      'Manager'
         10        SEND_VAR_EX                                                  !2
         11        SEND_VAR_EX                                                  !3
         12        DO_FCALL                                          0          
         13        SEND_VAR_NO_REF_EX                                           $7
         14        DO_FCALL                                          0          
  167    15        PRE_INC                                                      !4
         16    >   IS_SMALLER                                                   !4, !1
         17      > JMPNZ                                                        ~11, ->8
  166    18    > > JMP                                                          ->63
  170    19    >   IS_EQUAL                                                     !0, 'Marketer'
         20      > JMPZ                                                         ~12, ->34
  171    21    >   ASSIGN                                                       !4, 0
         22      > JMP                                                          ->31
  172    23    >   INIT_METHOD_CALL                                             'addWorker'
         24        NEW                                                  $14     'Marketer'
         25        SEND_VAR_EX                                                  !2
         26        SEND_VAR_EX                                                  !3
         27        DO_FCALL                                          0          
         28        SEND_VAR_NO_REF_EX                                           $14
         29        DO_FCALL                                          0          
  171    30        PRE_INC                                                      !4
         31    >   IS_SMALLER                                                   !4, !1
         32      > JMPNZ                                                        ~18, ->23
  170    33    > > JMP                                                          ->63
  174    34    >   IS_EQUAL                                                     !0, 'Engineer'
         35      > JMPZ                                                         ~19, ->49
  175    36    >   ASSIGN                                                       !4, 0
         37      > JMP                                                          ->46
  176    38    >   INIT_METHOD_CALL                                             'addWorker'
         39        NEW                                                  $21     'Engineer'
         40        SEND_VAR_EX                                                  !2
         41        SEND_VAR_EX                                                  !3
         42        DO_FCALL                                          0          
         43        SEND_VAR_NO_REF_EX                                           $21
         44        DO_FCALL                                          0          
  175    45        PRE_INC                                                      !4
         46    >   IS_SMALLER                                                   !4, !1
         47      > JMPNZ                                                        ~25, ->38
  174    48    > > JMP                                                          ->63
  178    49    >   IS_EQUAL                                                     !0, 'Analyst'
         50      > JMPZ                                                         ~26, ->63
  179    51    >   ASSIGN                                                       !4, 0
         52      > JMP                                                          ->61
  180    53    >   INIT_METHOD_CALL                                             'addWorker'
         54        NEW                                                  $28     'Analyst'
         55        SEND_VAR_EX                                                  !2
         56        SEND_VAR_EX                                                  !3
         57        DO_FCALL                                          0          
         58        SEND_VAR_NO_REF_EX                                           $28
         59        DO_FCALL                                          0          
  179    60        PRE_INC                                                      !4
         61    >   IS_SMALLER                                                   !4, !1
         62      > JMPNZ                                                        ~32, ->53
  183    63    > > RETURN                                                       null

End of function addworkerstodepartment

End of class Department.

Class Company:
Function adddepartment:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  addDepartment
number of ops:  5
compiled vars:  !0 = $department
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  189     0  E >   RECV                                                 !0      
  190     1        FETCH_OBJ_W                                          $1      'departments'
          2        ASSIGN_DIM                                                   $1
          3        OP_DATA                                                      !0
  191     4      > RETURN                                                       null

End of function adddepartment

Function getdepartments:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getDepartments
number of ops:  3
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  194     0  E >   FETCH_OBJ_R                                          ~0      'departments'
          1      > RETURN                                                       ~0
  195     2*     > RETURN                                                       null

End of function getdepartments

Function getdepartmentcount:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  getDepartmentCount
number of ops:  4
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  198     0  E >   FETCH_OBJ_R                                          ~0      'departments'
          1        COUNT                                                ~1      ~0
          2      > RETURN                                                       ~1
  199     3*     > RETURN                                                       null

End of function getdepartmentcount

End of class Company.

Class Tabel:
Function padleft:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  padLeft
number of ops:  13
compiled vars:  !0 = $value, !1 = $columnLength
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  204     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
  205     2        ECHO                                                         !0
  206     3        INIT_FCALL                                                   'str_repeat'
          4        SEND_VAL                                                     '+'
          5        INIT_FCALL                                                   'mb_strlen'
          6        SEND_VAR                                                     !0
          7        DO_ICALL                                             $2      
          8        SUB                                                  ~3      !1, $2
          9        SEND_VAL                                                     ~3
         10        DO_ICALL                                             $4      
         11        ECHO                                                         $4
  207    12      > RETURN                                                       null

End of function padleft

Function calculatiotofoutput:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aJdlK
function name:  calculatiotOfOutput
number of ops:  45
compiled vars:  !0 = $informarion, !1 = $col1, !2 = $col2, !3 = $col3, !4 = $col4, !5 = $col5, !6 = $col6
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  209     0  E >   RECV                                                 !0      
  210     1        ASSIGN                                                       !1, 15
  211     2        ASSIGN                                                       !2, 10
  212     3        ASSIGN                                                       !3, 10
  213     4        ASSIGN                                                       !4, 8
  214     5        ASSIGN                                                       !5, 8
  215     6        ASSIGN                                                       !6, 15
  217     7        INIT_METHOD_CALL                                             'padLeft'
          8        FETCH_DIM_R                                          ~13     !0, 'name'
          9        SEND_VAL                                                     ~13
         10        SEND_VAR                                                     !1
         11        DO_FCALL                                          0  $14     
  218    12        INIT_METHOD_CALL                                             'padLeft'
         13        FETCH_DIM_R                                          ~15     !0, 'count'
         14        SEND_VAL                                                     ~15
         15        SEND_VAR                                                     !2
         16        DO_FCALL                                          0  $16     
         17        CONCAT                                               ~17     $14, $16
  219    18        INIT_METHOD_CALL                                             'padLeft'
         19        FETCH_DIM_R                                          ~18     !0, 'salary'
         20        SEND_VAL                                                     ~18
         21        SEND_VAR                                                     !3
         22        DO_FCALL                                          0  $19     
         23        CONCAT                                               ~20     ~17, $19
  220    24        INIT_METHOD_CALL                                             'padLeft'
         25        FETCH_DIM_R                                          ~21     !0, 'coffee'
         26        SEND_VAL                                                     ~21
         27        SEND_VAR                                                     !4
         28        DO_FCALL                                          0  $22     
         29        CONCAT                                               ~23     ~20, $22
  221    30        INIT_METHOD_CALL                                             'padLeft'
         31        FETCH_DIM_R                                          ~24     !0, 'pages'
         32        SEND_VAL                                                     ~24
         33        SEND_VAR                                                     !5
         34        DO_FCALL                                          0  $25     
         35        CONCAT                                               ~26     ~23, $25
  222    36        INIT_METHOD_CALL                                             'padLeft'
         37        FETCH_DIM_R                                          ~27     !0, 'salaryDividePages'
         38        SEND_VAL                                                     ~27
         39        SEND_VAR                                                     !6
         40        DO_FCALL                                          0  $28     
         41        CONCAT                                               ~29     ~26, $28
         42        CONCAT                                               ~30     ~29, '%0A'
         43        ECHO                                                         ~30
  223    44      > RETURN                                                       null

End of function calculatiotofoutput

Function printtabel:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 10, Position 2 = 46
Branch analysis from position: 10
2 jumps found. (Code = 78) Position 1 = 11, Position 2 = 46
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
Branch analysis from position: 46
2 jumps found. (Code = 77) Position 1 = 54, Position 2 = 83
Branch analysis from position: 54
2 jumps found. (Code = 78) Position 1 = 55, Position 2 = 83
Branch analysis from position: 55
1 jumps found. (Code = 42) Position 1 = 54
Branch analysis from position: 54
Branch analysis from position: 83
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 83
Branch analysis from position: 46
filename:       /in/aJdlK
function name:  printTabel
number of ops:  138
compiled vars:  !0 = $company, !1 = $columnName, !2 = $departmentInformation, !3 = $department, !4 = $totalInformation, !5 = $averageInformation
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
  225     0  E >   RECV                                                 !0      
  227     1        ASSIGN                                                       !1, <array>
  234     2        INIT_METHOD_CALL                                             'calculatiotOfOutput'
          3        SEND_VAR                                                     !1
          4        DO_FCALL                                          0          
  236     5        ECHO                                                         '%0A'
  238     6        ASSIGN                                                       !2, <array>
  245     7        INIT_METHOD_CALL                                             !0, 'getDepartments'
          8        DO_FCALL                                          0  $9      
          9      > FE_RESET_R                                           $10     $9, ->46
         10    > > FE_FETCH_R                                                   $10, !3, ->46
  246    11    >   INIT_METHOD_CALL                                             !3, 'getDepartmentName'
         12        DO_FCALL                                          0  $12     
         13        ASSIGN_DIM                                                   !2, 'name'
         14        OP_DATA                                                      $12
  247    15        INIT_METHOD_CALL                                             !3, 'getNumberWorkers'
         16        DO_FCALL                                          0  $14     
         17        ASSIGN_DIM                                                   !2, 'count'
         18        OP_DATA                                                      $14
  248    19        INIT_METHOD_CALL                                             !3, 'getDepartmentSalary'
         20        DO_FCALL                                          0  $16     
         21        ASSIGN_DIM                                                   !2, 'salary'
         22        OP_DATA                                                      $16
  249    23        INIT_METHOD_CALL                                             !3, 'getDepartmentCoffee'
         24        DO_FCALL                                          0  $18     
         25        ASSIGN_DIM                                                   !2, 'coffee'
         26        OP_DATA                                                      $18
  250    27        INIT_METHOD_CALL                                             !3, 'getDepartmentPages'
         28        DO_FCALL                                          0  $20     
         29        ASSIGN_DIM                                                   !2, 'pages'
         30        OP_DATA                                                      $20
  251    31        INIT_FCALL                                                   'round'
         32        INIT_METHOD_CALL                                             !3, 'getDepartmentSalary'
         33        DO_FCALL                                          0  $22     
         34        INIT_METHOD_CALL                                             !3, 'getDepartmentPages'
         35        DO_FCALL                                          0  $23     
         36        DIV                                                  ~24     $22, $23
         37        SEND_VAL                                                     ~24
         38        SEND_VAL                                                     1
         39        DO_ICALL                                             $25     
         40        ASSIGN_DIM                                                   !2, 'salaryDividePages'
         41        OP_DATA                                                      $25
  252    42        INIT_METHOD_CALL                                             'calculatiotOfOutput'
         43        SEND_VAR                                                     !2
         44        DO_FCALL                                          0          
  245    45      > JMP                                                          ->10
         46    >   FE_FREE                                                      $10
  255    47        ECHO                                                         '%0A'
  257    48        ASSIGN                                                       !4, <array>
  264    49        ASSIGN_DIM                                                   !4, 'name'
         50        OP_DATA                                                      '%D0%92%D1%81%D0%B5%D0%B3%D0%BE'
  265    51        INIT_METHOD_CALL                                             !0, 'getDepartments'
         52        DO_FCALL                                          0  $29     
         53      > FE_RESET_R                                           $30     $29, ->83
         54    > > FE_FETCH_R                                                   $30, !3, ->83
  266    55    >   INIT_METHOD_CALL                                             !3, 'getNumberWorkers'
         56        DO_FCALL                                          0  $32     
         57        ASSIGN_DIM_OP                    +=               1          !4, 'count'
         58        OP_DATA                                                      $32
  267    59        INIT_METHOD_CALL                                             !3, 'getDepartmentSalary'
         60        DO_FCALL                                          0  $34     
         61        ASSIGN_DIM_OP                    +=               1          !4, 'salary'
         62        OP_DATA                                                      $34
  268    63        INIT_METHOD_CALL                                             !3, 'getDepartmentCoffee'
         64        DO_FCALL                                          0  $36     
         65        ASSIGN_DIM_OP                    +=               1          !4, 'coffee'
         66        OP_DATA                                                      $36
  269    67        INIT_METHOD_CALL                                             !3, 'getDepartmentPages'
         68        DO_FCALL                                          0  $38     
         69        ASSIGN_DIM_OP                    +=               1          !4, 'pages'
         70        OP_DATA                                                      $38
  270    71        INIT_FCALL                                                   'round'
         72        INIT_METHOD_CALL                                             !3, 'getDepartmentSalary'
         73        DO_FCALL                                          0  $40     
         74        INIT_METHOD_CALL                                             !3, 'getDepartmentPages'
         75        DO_FCALL                                          0  $41     
         76        DIV                                                  ~42     $40, $41
         77        SEND_VAL                                                     ~42
         78        SEND_VAL                                                     1
         79        DO_ICALL                                             $43     
         80        ASSIGN_DIM_OP                    +=               1          !4, 'salaryDividePages'
         81        OP_DATA                                                      $43
  265    82      > JMP                                                          ->54
         83    >   FE_FREE                                                      $30
  273    84        INIT_METHOD_CALL                                             'calculatiotOfOutput'
         85        SEND_VAR                                                     !4
         86        DO_FCALL                                          0          
  275    87        INIT_ARRAY                                           ~45     '%D0%A1%D1%80%D0%B5%D0%B4%D0%BD%D0%B5%D0%B5', 'name'
  276    88        INIT_FCALL                                                   'round'
         89        FETCH_DIM_R                                          ~46     !4, 'count'
         90        INIT_METHOD_CALL                                             !0, 'getDepartmentCount'
         91        DO_FCALL                                          0  $47     
         92        DIV                                                  ~48     ~46, $47
         93        SEND_VAL                                                     ~48
         94        SEND_VAL                                                     1
         95        DO_ICALL                                             $49     
         96        ADD_ARRAY_ELEMENT                                    ~45     $49, 'count'
  277    97        INIT_FCALL                                                   'round'
         98        FETCH_DIM_R                                          ~50     !4, 'salary'
         99        INIT_METHOD_CALL                                             !0, 'getDepartmentCount'
        100        DO_FCALL                                          0  $51     
        101        DIV                                                  ~52     ~50, $51
        102        SEND_VAL                                                     ~52
        103        SEND_VAL                                                     1
        104        DO_ICALL                                             $53     
        105        ADD_ARRAY_ELEMENT                                    ~45     $53, 'salary'
  278   106        INIT_FCALL                                                   'round'
        107        FETCH_DIM_R                                          ~54     !4, 'coffee'
        108        INIT_METHOD_CALL                                             !0, 'getDepartmentCount'
        109        DO_FCALL                                          0  $55     
        110        DIV                                                  ~56     ~54, $55
        111        SEND_VAL                                                     ~56
        112        SEND_VAL                                                     1
        113        DO_ICALL                                             $57     
        114        ADD_ARRAY_ELEMENT                                    ~45     $57, 'coffee'
  279   115        INIT_FCALL                                                   'round'
        116        FETCH_DIM_R                                          ~58     !4, 'pages'
        117        INIT_METHOD_CALL                                             !0, 'getDepartmentCount'
        118        DO_FCALL                                          0  $59     
        119        DIV                                                  ~60     ~58, $59
        120        SEND_VAL                                                     ~60
        121        SEND_VAL                                                     1
        122        DO_ICALL                                             $61     
        123        ADD_ARRAY_ELEMENT                                    ~45     $61, 'pages'
  280   124        INIT_FCALL                                                   'round'
        125        FETCH_DIM_R                                          ~62     !4, 'salaryDividePages'
        126        INIT_METHOD_CALL                                             !0, 'getDepartmentCount'
        127        DO_FCALL                                          0  $63     
        128        DIV                                                  ~64     ~62, $63
        129        SEND_VAL                                                     ~64
        130        DO_ICALL                                             $65     
        131        ADD_ARRAY_ELEMENT                                    ~45     $65, 'salaryDividePages'
        132        ADD_ARRAY_ELEMENT                                    ~45     1
  275   133        ASSIGN                                                       !5, ~45
  282   134        INIT_METHOD_CALL                                             'calculatiotOfOutput'
        135        SEND_VAR                                                     !5
        136        DO_FCALL                                          0          
  283   137      > RETURN                                                       null

End of function printtabel

End of class Tabel.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
236.53 ms | 1905 KiB | 15 Q