# Inserting a \circ inside a minted block [duplicate]

I'm trying to insert a \circ inside a minted block of code, to emit the following: g ∘ f:

$l.2 \PYG{n+nf}{g} \PYG{esc}{\circ} \PYG{n}{f} ... Am I holding it wrong? Is there a better way? • tested and works! marking as duplicate Sep 4 '17 at 14:29 • @koleygr thanks for the answer! Unfortunately it didn't work, if I replace |\circ| with just$\circ$, I get: g \$\circ\$f rendered. If I place it inside the ||, I get the same error (p.s. I fixed the error indentation, it was pasted wrong before) Sep 4 '17 at 14:36 • I just tested with: g |$\circ\$| f and works fine Sep 4 '17 at 14:38