In LaTeX, %
can be used for single-line comments. For multi-line comments, the following command is available in the verbatim
package.
\begin{comment}
Commented code
\end{comment}
But is there a simple command like /* code */
in C?
comments
In LaTeX, %
can be used for single-line comments. For multi-line comments, the following command is available in the verbatim
package.
\begin{comment}
Commented code
\end{comment}
But is there a simple command like /* code */
in C?
Best Answer
Following the C code paradigm, where one can use the preprocessor directives
something similar can be done in
TeX
(and descendants):The commented parts can be easily activated by replacing
\iffalse
with\iftrue
.