FANDOM


Brainfuck is a "simple" programming language. As not everyone knows it, I will explain below:

There are only 7 characters acceptable in Brainfuck. Anything else is considered comment.
Start with both-side infinitely long array and a pointer. (Imagine a tape and turing machine, but each cell can hold as big numbers as you want)
+ means to increase the value of cell the pointer is pointing.
- means to decrease the value of cell the pointer is pointing.
> means to move the pointer to the right.
< means to move the pointer to the left.
[ means where to go back from ].
] means to go back to corresponding [ unless the pointer is pointing a zero. (I mean, not a[0], but a[n]==0)
. means to display the number at which the pointer is pointing.
, means to get a number from standard input. Same as scanf in C language.
# means nothing, just make it easy for read (I put them between "sections," or "enters" in C).
(note: I slightly changed the definitions of ".")

Now, we have some programs we can use at googology:

  • duplicate
,[->+>+<<].
  • addition
,>,<[->+<].
  • multiplication
,>,#[-<[->>+>+<<<]#>>>[-<<<+>>>]<<#]>. //I know why it works

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.