Self-modifying BrianPh*ck
Jump to navigation
Jump to search
Paradigm(s) | imperative |
---|---|
Designed by | User:Orisphera |
Appeared in | 2023 |
Dimensions | one-dimensional |
Computational class | Unknown |
Reference implementation | Unimplemented |
File extension(s) | {{{files}}} |
Self-modifying BrianPh*ck is a joke language by User:Orisphera.
Commands
Self-modifying BrianPh*ck has the following commands:
Command | Description |
---|---|
>
|
Skip the next instruction |
<
|
Go into an infinite loop |
+
|
Put a , instead of the +
|
-
|
Put a , instead of the -
|
.
|
Output a dot |
,
|
Input a character and put it instead of the ,
|
[
|
Do nothing; used as a destination for ]
|
]
|
Jump back to the matching [
|
Anything else is a no-op. If a >
has one after it, it skips only the no-op, so
>_<
is an infinite loop, just like
>.<
is, although
><
isn't.
Examples
Quine:
.
(or any other program consisting only of .
's
Infinite loop:
<
or
[]
Conditional infinite loop:
[,]
If the first input other than +
, -
, or ,
is >
, it halts; if it's .
, it outputs infinite dots; if it's ]
, it crashes; otherwise, it goes into an infinite loop.