- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
public function k($heh) {
return ($heh == "") ? rand() : $heh;
}
// ...
$stars += count(array_intersect(
array($this->k($this->id_type), $this->k($this->id_type2), $this->k($this->id_type3)),
array($this->k($that->id_type), $this->k($that->id_type2), $this->k($that->id_type3))
));
// ...
и вот таким способом я и решил это реализовать.