Creating Multiple Choice Questions Without using 'Exam' Class
If all you want is to occasionally be able to ask multiple choice questions, then the exam class may be overkill. Here's a complete LaTeX file that defines both a choices
environment and a oneparchoices
environment, which you can use to list the choices. (I'm assuming here you'd use an enumerate
environment to list the questions.)
\documentclass{article}
%--------------------------------------------------------------------
%--------------------------------------------------------------------
\newcounter{choice}
\renewcommand\thechoice{\Alph{choice}}
\newcommand\choicelabel{\thechoice.}
\newenvironment{choices}%
{\list{\choicelabel}%
{\usecounter{choice}\def\makelabel##1{\hss\llap{##1}}%
\settowidth{\leftmargin}{W.\hskip\labelsep\hskip 2.5em}%
\def\choice{%
\item
} % choice
\labelwidth\leftmargin\advance\labelwidth-\labelsep
\topsep=0pt
\partopsep=0pt
}%
}%
{\endlist}
\newenvironment{oneparchoices}%
{%
\setcounter{choice}{0}%
\def\choice{%
\refstepcounter{choice}%
\ifnum\value{choice}>1\relax
\penalty -50\hskip 1em plus 1em\relax
\fi
\choicelabel
\nobreak\enskip
}% choice
% If we're continuing the paragraph containing the question,
% then leave a bit of space before the first choice:
\ifvmode\else\enskip\fi
\ignorespaces
}%
{}
%--------------------------------------------------------------------
%--------------------------------------------------------------------
%--------------------------------------------------------------------
\begin{document}
\begin{enumerate}
\item One of these things is not like the others; one of these things
is not the same. Which one doesn't belong?
\begin{choices}
\choice George
\choice Paul
\choice John
\choice Ringo
\choice Socrates
\end{choices}
\item What was the color of George Washinton's white horse?
\begin{choices}
\choice Green
\choice Yellow
\choice White
\end{choices}
\item One of these things is not like the others; one of these things
is not the same. Which one doesn't belong?
\begin{oneparchoices}
\choice George
\choice Paul
\choice John
\choice Ringo
\choice Socrates
\end{oneparchoices}
\item What was the color of George Washinton's white horse?
\begin{oneparchoices}
\choice Green
\choice Yellow
\choice White
\end{oneparchoices}
\item One of these things is not like the others; one of these things
is not the same. Which one doesn't belong?
\begin{oneparchoices}
\choice George
\choice Paul
\choice John
\choice Ringo
\choice Socrates
\end{oneparchoices}
\item What was the color of George Washinton's white horse?
\begin{oneparchoices}
\choice Green
\choice Yellow
\choice White
\end{oneparchoices}
\end{enumerate}
\end{document}
If you'd like a smaller indent for the choices
environment, you can decrease the \leftmargin
.
If you want to put QCM inside a table you have alterqcm
, this is a package of TeXLive
\documentclass[12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[upright]{fourier}%withot fourier symb = $\altersquare$
\usepackage{alterqcm}
\parindent0pt
\begin{document}
\begin{alterqcm}[lq=8cm,language=english]
\AQquestion{Question}{%
{Proposition 1},
{Proposition 2},
{Proposition 3}}
\AQquestion{Question}{%
{Proposition 1},
{Proposition 2},
{Proposition 3}}
\end{alterqcm}
\end{document}
Without "fourier", you need to use a font with the symbol \square
or you can use
in option symb = $\altersquare$
.
In the next version, it will be possible to add horizontal answers
You might also want to look at the exercise
package (it is not a class). It even allows you to display the answers at the end of a document.