Skip to content

Instantly share code, notes, and snippets.

name: binary increment1
source code: |
# Adds 1 to a binary number.
input: '00000000000000000000000000000000' # 32 - reject
blank: ' '
start state: q0
table:
# scan to the rightmost digit
q0:
0 : {write: ' ', R: q1}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.