# How do I define a new function \juse

I want to define a new function \juse which takes 3 parameters and prints the second one. However, this doesn't work:

\documentclass{article}
\newcommand\juse{#1#2#3}{#2}
\begin{document}
$\juse{ abc } {def} { ghi }$
\end{document}


It should print $def$ but gives an error.

• The correct syntax for LaTeX would be \newcommand\juse[3]{#2}
– user220367
Jul 27 '20 at 10:11

To define a command in LaTeX that takes three mandatory arguments you'd only have to add a [3] to it. So a complete example would be:
\documentclass{article}
$\juse{ abc } {def} { ghi }$

It is a bit unclear however, what you want to achieve with the command in a math enviroment, or if I got you wrong with the \$'s.