We are currently working on new rules for what content should and shouldn't be allowed on this website, and are looking for feedback! See Esolang:2026 topicality proposal to view and give feedback on the current draft.

Thue++

From Esolang
Jump to navigation Jump to search

Thue, but with RegEx (EMCAscript).
Capture groups exist, and can be accessed by the replacement text with $number.

Examples

Variables:

(var (\w*)="([^"]*)".*)\2::=$1$3

Thue Interpreter:

((\n|^)(\S+):{2}=(\S*)(\n.*\n|\n):{2}=\n.*)\3::=$1$4

Implementation

https://jsfiddle.net/1kbpuyxj/13/