# Bigger rows with fractions in pseudocode

I had previous question how to write pseudocode in latex. I would like to use fractions in pseudocode, but rows with fractions are a little small. Anybody know how to make rows with fractions a little bigger?

\usepackage{algpseudocode,amsmath}

\newcommand{\var}{\texttt}
\newcommand{\assign}{\leftarrow}
\newcommand{\multilinestate}{%
\parbox[t]{\linewidth}{\raggedright\hangindent=\algorithmicindent\hangafter=1
\strut#1\strut}}

\begin{algorithmic}
\State \multilinestate{$\var{maxWeight} \assign{}$\var{e.weight} where~\var{e} has maximum weight of all elements}
\State \multilinestate{$\var{minWeight} \assign{}$\var{e.weight} where~\var{e} has minimum weight of all elements}
\State $\var{maxDraw} \assign{}$maximum size in visualization
\State $\var{minDraw} \assign{}$minimum size in visualization\\
\Function {CountDrawSize}{\var{elementWeight}}
\If{$\var{maxWeight} = \var{minWeight}$}
\State\Return $\dfrac{(\var{maxWeight} + \var{minWeight})}{2}$
\Else
\State\Return $\var{minDraw} + \dfrac{(\var{elementWeight} - \var{minWeight})(\var{maxDraw} - \var{minDraw})}{(\var{maxWeight} - \var{minWeight})}$
\EndIf
\EndFunction\\
\end{algorithmic} • By small are you referring to the width or the height of the line?
– Werner
Dec 22, 2014 at 23:50
• @Werner I meant height
– Matt
Dec 22, 2014 at 23:57

Increase (locally) the \lineskip parameter:

\documentclass{article}
\usepackage{algpseudocode,amsmath}

\newcommand{\var}{\texttt}
\newcommand{\assign}{\leftarrow}
\newcommand{\multilinestate}{%
\parbox[t]{\linewidth}{\raggedright\hangindent=\algorithmicindent\hangafter=1
\strut#1\strut}}

\begin{document}

\begin{algorithmic}
\setlength{\lineskip}{3pt}
\State \multilinestate{$\var{maxWeight} \assign\var{e.weight}$ where~\var{e} has maximum weight of all elements}
\State \multilinestate{$\var{minWeight} \assign\var{e.weight}$ where~\var{e} has minimum weight of all elements}
\State $\var{maxDraw} \assign{}$maximum size in visualization
\State $\var{minDraw} \assign{}$minimum size in visualization\\
\Function {CountDrawSize}{\var{elementWeight}}
\If{$\var{maxWeight} = \var{minWeight}$}
\State\Return $\dfrac{(\var{maxWeight} + \var{minWeight})}{2}$
\Else
\State\Return $\var{minDraw} + \dfrac{(\var{elementWeight} - \var{minWeight})(\var{maxDraw} - \var{minDraw})}{(\var{maxWeight} - \var{minWeight})}$
\EndIf
\EndFunction
\end{algorithmic}

\end{document} 