public function get_last_step_with_qt_var($name) {
        foreach ($this->get_reverse_step_iterator() as $step) {
            if ($step->has_qt_var($name)) {
                return $step;
            }
        }
        return new question_attempt_step_read_only();
    }
public function get_last_step_with_qt_var($name) {
        foreach ($this->get_reverse_step_iterator() as $step) {
            if ($step->has_qt_var($name)) {
                return $step;
            }
        }
        return new question_attempt_step_read_only();
    }
public function get_last_step_with_qt_var ( $ name ) { foreach ( $ this -> get_reverse_step_iterator ( ) as $ step ) { if ( $ step -> has_qt_var ( $ name ) ) { return $ step ; } } return new question_attempt_step_read_only ( ) ; }
Get the last step with a particular question type varialbe set.
@param string $name the name of the variable to get.
@return question_attempt_step the last step, or a step with no variables
if there was not a real step.
Get the last step with a particular question type varialbe set .