Talk:Stroke

From Esolang
Jump to navigation Jump to search

Computational class

This doesn't seem to be Turing complete. This esolang is a finite-state machine. Every variable (bit) must be represented using literal | characters in the source code. Each program can access finitely many bits, therefore it's not Turing complete. --Hakerh400 (talk) 14:48, 29 May 2024 (UTC)


Well, yes, but isn't it just a technical limitation as the variables can have an arbitrary size? EDIT: Not really,I will fix the category information, thanks! --Ttulka (talk) 07:50 Thursday, 30 May 2024 (UTC)

A simpler turing complete version

A perhaps turing complete version of stroke, is one in which each variable is made up of:

VAR_INDEX_1 VAR_INDEX_2 

This references a variable of index VAR_INDEX_1+VAL(VAR_INDEX_2).
Thats not turing complete by itself, however, we can define that the not, instead of actually performing a not, performs an XOR on each byte in a bit with a 1, then adds another bit to the end of the string(which is of the binary value 0), and then last performs a bitwise NOT on the second to last bit. As such we can get any binary string length in one var, and then reference any variable, as such using infinite memory. However in this case the loop is perhaps a little harder to use. As such we can use:

/ VAR_INDEX_1 VAR_INDEX_2

which checks the binary digit of VAR_1 that has the index with the value of VAR_2. This is most likely turing complete. --Yayimhere2(school) (talk) 11:01, 12 November 2025 (UTC)

A simple variation of the above IS turing complete. We simply change the method of variable indexing. Simply, for any variable index, if it is referenced, it will be interpreted as index+1. if it gets referenced minus one index value, its index-1, obviously. We can translate the two level loop nesting, only plus brainfuck variant into this version of stroke(which I label distress, as all the bits seems quite...distressed):
[...] -> / | | \n ... \n \
+ -> | \n |
> -> just reference the last var again(just use a ||)
< -> last referenced var - 1(just use a |)
note that the loop has an input var, but that is ignored after the loop has been entered, as it instead references the last referenced variable, however still with the digit index thing I mentioned, however just using how many |'s as the index instead of the value of a variable. Note that \n is a newline. I think ill make a new page for this... --Yayimhere2(school) (talk) 05:21, 15 November 2025 (UTC)