 \(\textrm{COMPARE}\_\textrm{ALL}(q_j,q_n,a,b)\) The machine compares the sequences A and B marked with a and b respectively. This is done by repeatedly computing COMPARE_ERASE on a and b. If A and B are equal, all a’s and b’s will have been erased and the machine moves to state \(q_j\), else, it will move to state \(q_n\). It is computed by  \[\textrm{COMPARE}\_\textrm{ERASE}(\textrm{COMPARE}\_\textrm{ALL}(q_j,q_n,a,b),q_j,q_n,a,b)\]   and so by recursively calling \(\textrm{COMPARE}\_\textrm{ALL}\).