Quantcast
Channel: User sorry - TeX - LaTeX Stack Exchange
Viewing all articles
Browse latest Browse all 28

Two algorithms side by side and synchronized

$
0
0

I have the following MWE:

\documentclass{beamer}\usepackage{tikz}\usepackage[ruled,linesnumbered]{algorithm2e}\begin{document}\begin{frame}[t]{}    \begin{minipage}{0.5\textwidth}        \begin{algorithm}[H]            algo1-line1\\            algo1-still line 1 but in the next line\\            algo1-line2\\            algo1-line 3        \end{algorithm}    \end{minipage}    \begin{minipage}{0.5\textwidth}        \begin{algorithm}[H]            algo2-line1\\            algo2-line2\\            algo2-still line 2 but in the next line\\            algo2-line 3        \end{algorithm}    \end{minipage}\end{frame}\end{document}

What I wand to aim at is to have both algorithms side by side and to have the lines "synchronized", i.e. the following would be my desired output:

(1) algo1-line1                                        algo2-line1    algo1-still line 1 but in the next line(2) algo1-line2                                        algo2-line2                                                       algo2-still line 2 but in the next line(3) algo1-line 3                                       algo2-line 3

Would someone be so kind to help me with that?Thanks in advance


Viewing all articles
Browse latest Browse all 28

Latest Images

Trending Articles





Latest Images