\begin{Verbatim}[commandchars=\\\{\}]
\PYG{k+kn}{from} \PYG{n+nn}{Bio.PopGen} \PYG{k+kn}{import} \PYG{n}{GenePop}

\PYG{k}{with} \PYG{n+nb}{open}\PYG{p}{(}\PYG{l+s+s2}{\PYGZdq{}example.gen\PYGZdq{}}\PYG{p}{)} \PYG{k}{as} \PYG{n}{handle}\PYG{p}{:}
    \PYG{n}{rec} \PYG{o}{=} \PYG{n}{GenePop}\PYG{o}{.}\PYG{n}{read}\PYG{p}{(}\PYG{n}{handle}\PYG{p}{)}
\end{Verbatim}
