Skip to content

public Algo\Pairwise\Pairwise::candidateWinVersus

Read it at the source

Description

php
public Algo\Pairwise\Pairwise->candidateWinVersus ( CondorcetPHP\Condorcet\Candidate|string $candidate , CondorcetPHP\Condorcet\Candidate|string $opponent ): bool

Compare Candidate pairwise to another Candidate.

Parameters

candidate: CondorcetPHP\Condorcet\Candidate|string

the candidate to be compared

opponent: CondorcetPHP\Condorcet\Candidate|string

the candidate to be compared with $candidate

Return value

(bool) true if $a win, false if it lose or tie

Throws:

  • CondorcetPHP\Condorcet\Throwable\CandidateExistsException

Released under the MIT License.