Skip to content

Brainfuck Commands

Anar Software edited this page Jan 21, 2016 · 7 revisions

The Brainfuck language consists of only eight simple commands, each consisting of a single character:

Command Description

| Moves the pointer to the right < | Moves the pointer to the left

  • | Increases the byte at the data pointer
  • | Decreases the byte at the data pointer . | Outputs the byte at the data pointer , | Inputs a byte into memory cell at the data pointer [ | Jumps past the matching ] if the byte at the data pointer is 0 ] | Jumps back to the matching [ if the byte at the data pointer is not 0

| Outputs the all bytes in the memory. (when -debug parameter is used)

All characters other than ><+-.,[] should be considered comments and ignored, except only when you run the Brainfuck Interpreter with -debug parameter, command # (hash / number sign) dumps the whole memory for you to debug it; check out the Memory Dump Example for more information.