1 | <?php |
||
9 | class Statistics |
||
10 | { |
||
11 | protected $lengths = array(); |
||
12 | |||
13 | protected $elements; |
||
14 | |||
15 | /** |
||
16 | * @param array $elements |
||
17 | */ |
||
18 | public function __construct(array $elements) |
||
25 | |||
26 | /** |
||
27 | * Получаем возможные сочетания элементов массива |
||
28 | * |
||
29 | * @return array |
||
30 | */ |
||
31 | public function getCombinations() |
||
48 | |||
49 | protected function getElement($i, $j) |
||
53 | |||
54 | /** |
||
55 | * @return array |
||
56 | */ |
||
57 | protected function getCounter() |
||
74 | |||
75 | /** |
||
76 | * @return integer |
||
77 | */ |
||
78 | protected function getCounterLimit() |
||
87 | |||
88 | /** |
||
89 | * Получение частного и остатка от деления |
||
90 | * |
||
91 | * @param integer $n |
||
92 | * @param integer $d |
||
93 | * |
||
94 | * @return array |
||
95 | */ |
||
96 | protected function divQr($n, $d) |
||
100 | } |
This checks looks for assignemnts to variables using the
list(...)
function, where not all assigned variables are subsequently used.Consider the following code example.
Only the variables
$a
and$c
are used. There was no need to assign$b
.Instead, the list call could have been.