The following conditional is not working; when I use \def\Assignment{Examples}, the file \input{\code/Assessment/#1/#2/#2} is not read.
\ifx\Assignment Examples
\qformat{\underline{\textbf{#5 \thequestion } }}
\loop
\input{\code/Assessment/#1/#2/#2}
\addtocounter{int}{1}\ifnum\value{int}<#4 \repeat
\else
\if\Assignment Quiz
\scriptsize{\textbf{This assessment instrument assesses the following Course Learning Outcomes (CLO) and grading scheme: }} \vspace{-0.25em}
\qformat{\underline{\textbf{#5 \thequestion } }\droptotalpoints}
\loop
\input{\code/Assessment/#1/#2/CLO}
\input{\code/Assessment/#1/#2/#2}
\addtocounter{int}{1}\ifnum\value{int}<#4 \repeat
\fi
\fi
} \rmfamily}{\medskip}
\ifx\Assignment Exampleswill fail because it compares the token\Assignmentto the tokenE. Also later on\if\Assignment Quizdoes not have thexin\ifxand if it would it would fail for the same reason (comparing\AssignmenttoQ). – Marijn May 15 '21 at 12:15\ifx\Assignment Eis always false as\Assignmentis notEalso\scriptsize{makes the rest of the document script size, latex size commands do not take an argument. – David Carlisle May 15 '21 at 12:30\loopmacros. – David Carlisle May 15 '21 at 12:36