I know the reason is the incompatibility of the packages, but I tried all the possibilities and I couldn't reach to the point of removing '=0' without changing the algorithm style I want. .
\documentclass{IEEEtran}
%\usepackage{algorithm}
%\usepackage{algorithmicx}
%\usepackage{algcompatible}
\usepackage[linesnumbered,ruled]{algorithm2e}
\usepackage[noend]{algpseudocode}% http://ctan.org/pkg/algorithmicx
\usepackage{float}
\begin{document}
\begin{algorithm}
\SetKwInOut{Input}{Input}
\SetKwInOut{Output}{Output}
\Input{The .}
\Output{M $T$.}
\Procedure {Update}{$Index, CurrentNode$}\\
\eIf {$index$ not in $CurrentNode.MapTable$}{
\begin{algorithmic}[1]
\State Create a new entry in $CurrentNode.MapTable$\;
\State Insert $index$ in the new entry\;
\State Create a new node $E$\;
\State Create a new entry in the $CurrentNode.children$, correspond to
previously created entry\;
\State Make the new entry point to E\;
\State $E.parent$ $\leftarrow$ $CurrentNode$\;
\State $CurrentNode$ $\leftarrow$ $E$\;
\State Initialize $CurrentNode$ materialization and entries\;
\end{algorithmic}
}{
\begin{algorithmic}[1]
\State Child pointed by\;
\State Update \;
\end{algorithmic}
}
\EndProcedure \\
\For{$i\leftarrow 1$ \KwTo $N$}{
\For{$l\leftarrow 1$ \KwTo $h$}{
\State $index [l]$ $\leftarrow$ generate index of data object $O_i$
for level $l$ using $W_l$\;
}
\eIf{$T.root$ is Null }{
\State Create a $root$ node \;
}{
\State $CurrentNode$ =\ $root$ \;
\CALL \textsc{Update}{$(Index, CurrentNode)$}\;
}
\For{$l\leftarrow 2$ \KwTo $h-1$}{
\CALL \textsc{Update}{$(Index, CurrentNode)$}\;
}
}
\caption{Build}
\end{algorithm}
\end{document}
>in the input, mark the code and press the curly braces in the input editor. That way the code gets proper highlighting. – Johannes_B Mar 19 '19 at 06:10algorithm2eandalgorithmicx. Also see Algoritmic return command = 0 (possible duplicate). – Werner Mar 19 '19 at 06:20algpseudocodeis part of thealgorithmicxpackage – DG' Mar 19 '19 at 06:35