lastBitOne and lastBitZero: final-symbol languages #
Strings whose last bit is 1 (resp. 0); the empty string is not in
either language. Decided by a 3-state scannerTM instance: the scan state
is the last bit seen so far, or none if no bit has been read.
Main definitions #
Language.lastBitOne,Language.lastBitZero.TM.lastBitTM target—scannerTMspecialized totarget : Bool.
Main results #
lastBitOne_in_DTIME,lastBitZero_in_DTIME— both inDTIME(n + 2).lastBitOne_mem_P,lastBitZero_mem_P.
lastBitZero ∈ DTIME(n + 2).
lastBitOne ∈ DTIME(n + 2).