Execute Brain****/Icon: Difference between revisions
Content added Content deleted
(Updated entry to account for nested brackets, reformatted to shorten source line lengths, touched on the ruler, added hello option to test nested brackets) |
m (Fixed syntax highlighting.) |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
{{implementation|Brainf***}}{{collection|RCBF}} |
|||
This version of BF takes program and input from the parameter list. |
This version of BF takes program and input from the parameter list. |
||
Memory grows as needed from a single cell. |
Memory grows as needed from a single cell. |
||
Line 4: | Line 5: | ||
<pre>BF programtext inputtext</pre> |
<pre>BF programtext inputtext</pre> |
||
<syntaxhighlight lang="icon"># |
|||
<lang Icon># |
|||
# bf interpreter |
# bf interpreter |
||
# |
# |
||
Line 99: | Line 100: | ||
# everything else is ignored/comment |
# everything else is ignored/comment |
||
} |
} |
||
end</ |
end</syntaxhighlight> |
||
Sample output: |
Sample output: |
Latest revision as of 11:25, 1 September 2022
Execute Brain****/Icon is an implementation of Brainf***.
Other implementations of Brainf***.
Execute Brain****/Icon is part of RCBF. You may find other members of RCBF at Category:RCBF.
This version of BF takes program and input from the parameter list. Memory grows as needed from a single cell. If no program is specified, the hello world program is run.
BF programtext inputtext
Sample output:
#BF Program is well formed. Program="++++++++++[>+>+++>++++>+++++++>++++++++>+++++++++>++++++++++>+++++++++++>++++++++++++<<<<<<<<<-]>>>>+.>>>>+..<.<++++++++.>>>+.<<+.<<<<++++.<++.>>>+++++++.>>>.+++.<+++++++.--------.<<<<<+.<+++.---." Ruler ="0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345" Goodbye, World! #BF hello Program is well formed. Program=">++++++++[<+++++++++>-]<.>>+>+>++>[-]+<[>[->+<<++++>]<<]>.+++++++..+++.>>+++++++.<<<[[-]<[-]>]<+++++++++++++++.>>.+++.------.--------.>>+.>++++." Ruler ="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123" Hello World!