I'm trying to typeset a pseudo code with an \If block without the matching \EndIf using algpseudocode. This is my MWE:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{geometry}
\usepackage{algorithm}
\usepackage{algpseudocode}
\begin{document}
% Insert the algorithm
\begin{algorithm}
\caption{Compute some function by recursive algorithm}
\begin{algorithmic}[1]
\Function{$some$}{m,n}
\If{$n=1$ \textit{or} $m=1$}
\State \Return 1
\Else
\State \Return $some(n,m-1)+some(n-1,m)+some(n-1,m-1)$
\EndFunction
\end{algorithmic}
\end{algorithm}
\end{document}
But I get the error: missing number, treated as zero. What do I do to make the \If code without the matching \EndIf?

algpseudocodewith thenoendoption (\usepackage[noend]{algpseudocode})? You must still use the\EndIfto tell where the code indentation ends, but it will not be printed. – Phelype Oleinik Apr 03 '18 at 00:10