如何使用WinEDT輸出do-while-loop問題

導入圖片下的包,然後輸入相應的命令即可解決

\documentclass{article}
\usepackage{algorithmicx}
\usepackage{algpseudocode}

\algdef{SE}[DOWHILE]{Do}{doWhile}{\algorithmicdo}[1]{\algorithmicwhile\ #1}%

\begin{document}
\begin{algorithmic}
  \Do
    \State Something
  \doWhile{$u \neq v$} % <--- use \doWhile for the "while" at the end
\end{algorithmic}
\end{document}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章