Keys

From Esolang
Jump to navigation Jump to search

Keys is a joke language created by User:A.

Syntax

Keys will end programs with 2 states kept: One is accepted, one is non-accepted. Making the keys (the first line) and the lock (the second line) match is sufficient for changing the state from non-accepted into accepted.

Example programs

This is an accepted program:

\_/--\_/--
\_/--\_/--

This is not:

\_/--\_/-_
\_/--\_/--

They do not match; and the carves of the keys or locks cannot change from - to _ and vice versa; otherwise it would be impossible to insert the key to unlock the lock.

This is also not an accepted program:

\/_
/\-

There are two more things to know: If the preceding code is /, then the next byte in theprogram should not change to _. If the preceding code is \, then the next byte in the program should not change to -.

Implementations

A Python interpreter by User:Bangyen.