- This is a featured language.
|Designed by||Matthew Cooke,Thomas Burnip|
|Computational class||Turing complete|
|Major implementations||Python Interpreter|
Twoee because Thue isn't bad enough. This is not 100% backwards compatible. We have "improved" it.
This is a comment (any text without an operator) Yes twoee has comments Replace a with b a::=b Replace a with inputed text a::=::: Replace a with b and output c a::=b~~~c Replace a with inputed text print c a::=:::~~~c This will define the data string ;;=a
Proper implementation of literal and non literal operators i.e. not have such a hacky fix for making ~~~ run after :::
All possible operators
This defines a command ::= This defines the data string ;;=
This tells the interpreter to take an input from the user ::: Prompted input ~::Prompt This outputs the text following it (text is treated as a literal) ~~~
This proves that our design aims have been met
This is the exmaple Twoee File. It should output: [whatever you typed first] You replaced d with e! [what ever you typed second] You replaced f with the string you typed! [What ever you typed] b[whatever you typed second]e[whatever you typed second][you final input] a::=b c::=::: d::=e~~~You replaced d with e! f::=:::~~~You replaced f with the string you typed! g::=~::Add your input? ;;=acdfg
a::=Hello b::= World ;;=ab
Some notes on execution
This does not chose a random possible substitution and run it, instead it will always run the first possible substitution. Therefore the order they are defined in will set their precedence.
There are a few structural changes to how files are laid out as well compared to Thue. For example the data string is no longer defined as whatever comes after a line with only ::= on it but as whatever follows the ;;= operator. All operators are 3 characters long.
- Add file input and output
- Have a single variable that is equal to the data string