I wonder what is the difference or correct usage of \lstinline!...!
and \lstinline{...}
?
I like better {}
because I feel there it's more consistent with other commands but for example in below example brackets don't work so I have to use !!
.
\documentclass[]{article}
\usepackage{listings}
\begin{document}
This line is fine I can use \lstinline{inline listings with brackets}.
begin{center}
\begin{tabular}{ c l }
Example & Explanation \\ \hline
\lstinline!$#! & This works\\
\lstinline{$*} & But how come this doesn't? \\
\end{tabular}
\end{center}
\end{document}
Why is that?
What would be the rule of thumb for !!
and {}
?