AAAAAAAAAAAAAA!!!!
(Redirected from AAAAAAAAAAAAAA!!!! Program)
AAAAAAAAAAAAAA!!!! is an esoteric programming language by User:Zzo38 which consists entirely of the letter A, spaces, commas, and exclamation points. If you type a line beginning with @, it can be a comment and can contain anything, but it must be removed from the program before the interpreter can run it. If you type a newline, it can count as a space, and multiple consecutive spaces or exclamation points can count as a single one.
Commands
AA AAA n!
Outputs number as a characterAAA AAAA AA n!
Input a character store to index nAAA AA n!
Go to label nAAAAA n!
Define a label nAAA AAAA AAA n!
Skip n commandsAAAA AA n!
Shift indexes n backwardsAAAA AAAA n!
Shift indexes n forwardsAA AAAA AA!
End programAAA A AAA n!
Begin define subroutine named nAAAA A AAA!
End define subroutineAAA A AA AAAA n!
End subroutine, return value nAAAAAA n!
Call subroutine nAAAA, AAAA n!
Forget n entries from subroutine stackAAAA AAA n!
Increment value at index nAAAA AAA, n!
Decrement value at index n unless value is zeroAAAA, A n!
Set command change register to nAAAA, AA A n!
Change all commands in program that start with what is in command change register to start with n insteadAAAA, AA AAA n!
Change all commands in program that end with what is in command change register to end with n insteadAAAAA, AA A n!
Change all commands in program that start with n to start with what is in command change register insteadAAAAA, AA AAA n!
Change all commands in program that end with n to end with what is in command change register insteadAAAAA, AAAAA!
Clear command change registerAAAAA, AAAA A n!
Add block of n number of A's at end of command change registerAAAAA, AAAA AAA n!
Add block of n number of A's and comma at end of command change register- (Any invalid command or operators, when reached by the program pointer, causes a fatal error, and does not allow the output that the program already made to be used for any purpose except for debugging this program.)
Operators
AAAA
= 0AAA
= 1A
= 2AA A
= 3AAAA A
= last index number read by a previous commandAAAAA, n
= value at index nAA A, a b
= a+bAA AA, a b
= abs(a-b)AAA, a b
= a*bAA AAA, a b
= a AND bAAAA, a b
= a XOR bAAAAAA n, a b
= Call subroutine n with parameter a and b, then return valueAAAAA A n, a
= Call subroutine n with parameter a and a, then return valueAAAAA AA
= First parameterAAAAA AAA
= Second parameter
Examples
AAAAA A! AAA AAAA AA A! AA AAA AAAAA, A! AAA AA A! AA AAAA AA!
- output "He"
AA AAA AA AA, AAA, AAA, AA A AAA, AA A AA A AA A AAA, AA A AA A! AA AAA AA A, AAA AAAAA A AAAA, AAA! AA AAAA AA! AAA A AAA AAAA! AAA A AA AAAA AAA, AA A, AAA AAA, AA A AA A AA A, AAA AAA, AA A AA A! AAAA A AAA!
@input to 2 AAA AAAA AA A! @label 2 AAAAA A! @output index 2 AA AAA AAAAA, A! @skip (diff (index 2), (mult 2, (mult 2, (mult 2, (mult 2, 3 ))))) AAA AAAA AAA AA AA, AAAAA, A AAA, A AAA, A AAA, A AAA, A AA A! @goto 2 AAA AA A! @end program AA AAAA AA!
Computational class
AAAAAAAAAAAAAA!!!! is proven to be Turing-complete, as one can simulate a cyclic tag system in this language.
See Also
- AAAAAAAAAAAAAA!!!! Turing-completeness proof
- AAAAAAAAA! (This is something similar, although unrelated)
- Rubyで作る奇妙なプログラミング言語 — A book to mention this language, along with some other esolangs.