\documentclass{article}
\usepackage{a4wide}
\usepackage{adjustbox}
\usepackage{fancyhdr}
\usepackage{tikz}
\usepackage{ifthen}
\usetikzlibrary{automata}
\usepackage{datetime}
\lhead{./certificates/march3testa1-march3testa2/sim-506.tex}
\rhead{09:48:10.579 on 2025-03-31}
\fancyfoot{}
\begin{document}
\newif\ifntiny
%\ntinyfalse
\ntinytrue
\thispagestyle{fancy}
\begin{center}
\maxsizebox{!}{0.475\textheight}{
\minsizebox{\textwidth}{!}{
\begin{tabular}{@{}c@{}}
% node count = 23
\begin{tikzpicture}[rotate = 0]
%\begin{tikzpicture}[rotate = 90]
\tikzset{initial text=$ $}

\node[accepting, state] at (12,-14) (n0n0n0n1n0n1n0) {$p!$\,\ifntiny{\tiny 717}\fi};
\node[accepting, state] at (12,-12) (n0n0n0n1n0n1) {$p?$\,\ifntiny{\tiny 718}\fi};
\node[accepting, state] at (11,-10) (n0n0n0n1n0) {$p?$\,\ifntiny{\tiny 719}\fi};
\node[initial, state] at (11,0) (n) {$p?$\,\ifntiny{\tiny 1231}\fi};
\node[accepting, state] at (5,-12) (n0n0n0n0n0n2) {$p?$\,\ifntiny{\tiny 580}\fi};
\node[accepting, state] at (20,-10) (n0n2n0n1n0) {$p!$\,\ifntiny{\tiny 577}\fi};
\node[accepting, state] at (20,-8) (n0n2n0n1) {$p?$\,\ifntiny{\tiny 578}\fi};
\node[accepting, state] at (6,-16) (n0n0n0n0n0n2n0n1) {$p?$\,\ifntiny{\tiny 578}\fi};
\node[state] at (11,-2) (n0) {$\cup$\,\ifntiny{\tiny 1230}\fi};
\node[accepting, state] at (9,-12) (n0n0n0n1n0n0) {$p!$\,\ifntiny{\tiny 711}\fi};
\node[state] at (1,-12) (n0n0n0n0n0n1) {$p?$\,\ifntiny{\tiny 1220}\fi};
\node[accepting, state] at (3,-16) (n0n0n0n0n0n2n0n0) {$p!$\,\ifntiny{\tiny 571}\fi};
\node[state] at (4,-10) (n0n0n0n0n0) {$\cup$\,\ifntiny{\tiny 1221}\fi};
\node[state] at (4,-8) (n0n0n0n0) {$p?$\,\ifntiny{\tiny 1222}\fi};
\node[state] at (7,-6) (n0n0n0) {$\cup$\,\ifntiny{\tiny 1223}\fi};
\node[state] at (7,-4) (n0n0) {$p?$\,\ifntiny{\tiny 1232}\fi};
\node[accepting, state] at (17,-8) (n0n2n0n0) {$p!$\,\ifntiny{\tiny 571}\fi};
\node[state] at (15,-4) (n0n1) {$p?$\,\ifntiny{\tiny 1229}\fi};
\node[accepting, state] at (6,-18) (n0n0n0n0n0n2n0n1n0) {$p!$\,\ifntiny{\tiny 577}\fi};
\node[accepting, state] at (11,-8) (n0n0n0n1) {$p?$\,\ifntiny{\tiny 720}\fi};
\node[accepting, state] at (19,-4) (n0n2) {$p?$\,\ifntiny{\tiny 580}\fi};
\node[accepting, state] at (19,-6) (n0n2n0) {$p?$\,\ifntiny{\tiny 579}\fi};
\node[accepting, state] at (5,-14) (n0n0n0n0n0n2n0) {$p?$\,\ifntiny{\tiny 579}\fi};

\draw[->, thick] (n) edge [near start, left] node {a} (n0);
\draw[->, thick] (n0) edge [near start, left] node {} (n0n0);
\draw[->, thick] (n0) edge [near start, left] node {} (n0n1);
\draw[->, thick] (n0) edge [near start, left] node {} (n0n2);
\draw[->, thick] (n0n0) edge [near start, left] node {a} (n0n0n0);
\draw[->, thick] (n0n0) edge [near start, right, bend right] node {b} (n);
\draw[->, thick] (n0n0n0) edge [near start, left] node {} (n0n0n0n0);
\draw[->, thick] (n0n0n0) edge [near start, left] node {} (n0n0n0n1);
\draw[->, thick] (n0n0n0n0) edge [near start, left] node {a} (n0n0n0n0n0);
\draw[->, thick] (n0n0n0n0n0) edge [near start, right, bend right] node {} (n0n0);
\draw[->, thick] (n0n0n0n0n0) edge [near start, left] node {} (n0n0n0n0n0n1);
\draw[->, thick] (n0n0n0n0n0) edge [near start, left] node {} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n1) edge [near start, right, bend right] node {a} (n0n0n0n0n0);
\draw[->, thick] (n0n0n0n0n0n2) edge [near start, left] node {a} (n0n0n0n0n0n2n0);
\draw[->, thick] (n0n0n0n0n0n2n0) edge [near start, left] node {a} (n0n0n0n0n0n2n0n0);
\draw[->, thick] (n0n0n0n0n0n2n0) edge [near start, left] node {b} (n0n0n0n0n0n2n0n1);
\draw[->, thick] (n0n0n0n0n0n2n0n0) edge [near start, right, bend right] node {x1} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n2n0n0) edge [near start, right, bend right] node {x2} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n2n0n0) edge [near start, right, bend right] node {x3} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n2n0n1) edge [near start, left] node {a} (n0n0n0n0n0n2n0n1n0);
\draw[->, thick] (n0n0n0n0n0n2n0n1n0) edge [near start, left, bend left] node {x1} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n2n0n1n0) edge [near start, left, bend left] node {x2} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n0n0n2n0n1n0) edge [near start, left, bend left] node {x3} (n0n0n0n0n0n2);
\draw[->, thick] (n0n0n0n1) edge [near start, left] node {a} (n0n0n0n1n0);
\draw[->, thick] (n0n0n0n1n0) edge [near start, left] node {a} (n0n0n0n1n0n0);
\draw[->, thick] (n0n0n0n1n0) edge [near start, left] node {b} (n0n0n0n1n0n1);
\draw[->, thick] (n0n0n0n1n0n0) edge [near start, right, bend right] node {x1} (n0n0n0n1);
\draw[->, thick] (n0n0n0n1n0n0) edge [near start, right, bend right] node {x2} (n0n0n0n1);
\draw[->, thick] (n0n0n0n1n0n0) edge [near start, right, bend right] node {x3} (n0n0n0n1);
\draw[->, thick] (n0n0n0n1n0n1) edge [near start, left] node {a} (n0n0n0n1n0n1n0);
\draw[->, thick] (n0n0n0n1n0n1n0) edge [near start, left, bend left] node {x1} (n0n0n0n1);
\draw[->, thick] (n0n0n0n1n0n1n0) edge [near start, left, bend left] node {x2} (n0n0n0n1);
\draw[->, thick] (n0n0n0n1n0n1n0) edge [near start, left, bend left] node {x3} (n0n0n0n1);
\draw[->, thick] (n0n1) edge [near start, left, bend left] node {a} (n0);
\draw[->, thick] (n0n2) edge [near start, left] node {a} (n0n2n0);
\draw[->, thick] (n0n2n0) edge [near start, left] node {a} (n0n2n0n0);
\draw[->, thick] (n0n2n0) edge [near start, left] node {b} (n0n2n0n1);
\draw[->, thick] (n0n2n0n0) edge [near start, right, bend right] node {x1} (n0n2);
\draw[->, thick] (n0n2n0n0) edge [near start, right, bend right] node {x2} (n0n2);
\draw[->, thick] (n0n2n0n0) edge [near start, right, bend right] node {x3} (n0n2);
\draw[->, thick] (n0n2n0n1) edge [near start, left] node {a} (n0n2n0n1n0);
\draw[->, thick] (n0n2n0n1n0) edge [near start, left, bend left] node {x1} (n0n2);
\draw[->, thick] (n0n2n0n1n0) edge [near start, left, bend left] node {x2} (n0n2);
\draw[->, thick] (n0n2n0n1n0) edge [near start, left, bend left] node {x3} (n0n2);

\end{tikzpicture}
\end{tabular}}}
\end{center}
\end{document}
