src/Question/MultipleChoiceQuestion.php
protected function selectChoice()
    {
        $index = array_search(
            $this->choices[$this->cursor->getPosition()],
            $this->answers
        );

        if (false !== $index) {
            unset($this->answers[$index]);
        } else {
            $this->answers[] = $this->choices[$this->cursor->getPosition()];
        }

        $this->answers = array_values($this->answers);

        return $this;
    }
protected function selectChoice()
    {
        $index = array_search(
            $this->choices[$this->cursor->getPosition()],
            $this->answers
        );

        if (false !== $index) {
            unset($this->answers[$index]);
        } else {
            $this->answers[] = $this->choices[$this->cursor->getPosition()];
        }

        $this->answers = array_values($this->answers);

        return $this;
    }
protected function selectChoice ( ) { $ index = array_search ( $ this -> choices [ $ this -> cursor -> getPosition ( ) ] , $ this -> answers ) ; if ( false !== $ index ) { unset ( $ this -> answers [ $ index ] ) ; } else { $ this -> answers [ ] = $ this -> choices [ $ this -> cursor -> getPosition ( ) ] ; } $ this -> answers = array_values ( $ this -> answers ) ; return $ this ; }
Allows selecting multiple choices

@return $this
Allows selecting multiple choices