Algorithm3.3.1A recognition Algorithm for \(L_3\)
Let \(s=s_1s_2\cdots s_n\in B^*\). This algorithm determines the truth value of \(s\in L_3\). The truth value is returned as the value of Word.
\(Word = true\)
If \(n>0\) then
If \(s_1=1\) then \(Word= false\) and exit
-
for \(i=3\) to \(n\):
\(\quad \) if \(s_{i-1}=1\) and \(s_i=1\) then \(Word = false\)