# How to complete the algorithm using algorithm2e [closed]

I wanted to write this flowchart using

\usepackage[linesnumbered,ruled,vlined]{algorithm2e}


However, I couldn't get what I want, please refer to my code in below

\begin{algorithm}
\DontPrintSemicolon
\KwIn{Data 1,2 to n }
\KwOut{Optimal $\alpha$ and $\beta$}
\If{ Condtion 1} {pass $\alpha_{0},\beta_{0}$}
\ElseIf {Condtion 2}{pass $\alpha_{1},\beta_{1}$}
\ElseIf {Condtion 3}{pass $\alpha_{2},\beta_{2}$}
\ElseIf {Condtion 4}{pass $\alpha_{3},\beta_{3}$}
\Else
{pass $\alpha_{4},\beta_{4}$}
\caption{Algorithm to obtain optimal $\alpha$}
\label{algo1}
\end{algorithm}


So how I can edit this according to the picture I have attached?

## closed as unclear what you're asking by egreg, Mensch, Joseph Wright♦May 7 '16 at 20:43

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

• Do you want to keep the formatting produced by algorithm2e or do you want to keep the formatting in the image? The algorithm2e formatting is very different from the one in the image. – Gonzalo Medina Apr 11 '14 at 12:57
• @GonzaloMedina what ever, but I am familiar with algorithm2e – Lovemath Apr 11 '14 at 13:00
• @GonzaloMedina Thanks for your answer, but it would be better if you could don't add a picture in the algorithm. Having said that my actual conditions are pretty big. So can't include the picture like that. – Lovemath Apr 11 '14 at 21:58
• Then please add a realistic example of what you want to achieve. I guess I'll delete my answer. – Gonzalo Medina Apr 11 '14 at 22:12