\documentclass[tikz,convert={outfile=\jobname.svg}]{standalone}

% This is a LaTeX file that uses a package called "tikz".  To include a tikz
% image in your document, put \usepackage{tikz} and any \usetikzpackage{...}
% commands between \documentclass{...} and \begin{document}.  Everything between
% \begin{tikzpicture} and \end{tikzpicture} defines the picture.

\usetikzlibrary{automata}

\begin{document}


\begin{tikzpicture}
\node[state, initial]   (q1) at (0,0) {$q_1$};
\node[state]            (q2) at (3,0) {$q_2$};
\node[state, accepting] (q3) at (5,0) {$q_3$};
\node[state]            (q4) at (3,3) {$q_4$};


\draw[->] (q1) edge             node[above left] {0}   (q4)
               edge             node[above] {1}   (q2)
          (q2) edge             node[right] {0}   (q4)
               edge             node[above] {1}   (q3)
          (q3) edge[loop right] node[right] {0,1} (q3);

\end{tikzpicture}

\end{document}
