I am new to LaTeX. I have to add C code in my document, I looked for examles and found the following way to add it. But the problem is there is no proper color displying like comments and code is displaying in the same color. Could you please tell me how to fix it?
Here is an example based on C code display in eclipse.
\begin{lstlisting}
int abc = 3; //Variable for reference
\end{lstlisting}
Best Answer
You can adopt this piece of code to customize more options
The result is