correct_answer: Check the Answer To a Question

View source: R/wordquiz.R

correct_answerR Documentation

Check the Answer To a Question

Description

Check the Answer To a Question

Usage

correct_answer(answer, question, rm_trailing_chars = "")

Arguments

answer

character string giving the answer to the question

question

the wordquestion object that was queried.

rm_trailing_chars

a character of length one containing characters that should be removed if they appear at the end of an answer. This can be used to omit rejecting answers because a key next to Return is hit by accident. For a Swiss keyboard, rm_trailing_chars = "$" is an appropriate choice.

Value

a logical indicating whether the answer is correct


stibu81/WordBox documentation built on Nov. 28, 2024, 2:29 p.m.