![インライン if とコメントを含む追加行](https://rvso.com/image/472726/%E3%82%A4%E3%83%B3%E3%83%A9%E3%82%A4%E3%83%B3%20if%20%E3%81%A8%E3%82%B3%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E5%90%AB%E3%82%80%E8%BF%BD%E5%8A%A0%E8%A1%8C.png)
algorithm2e を使ってアルゴリズムを書いています。
\lIf
と同じ行にコメントを付けて、インライン if を実行したいと思います\Comment*
。
\documentclass{article}
\usepackage[vlined,boxed,linesnumbered]{algorithm2e}
\DontPrintSemicolon
\SetKwIF{If}{ElseIf}{Else}{if}{then}{else if}{else}{}
\SetKwComment{Comment}{}{}
\begin{document}
\begin{algorithm}[ht]
\lIf{true}{%
foo \Comment*{bar}
}
\caption{Test}
\end{algorithm}
\end{document}
どうやって削除するのですか?