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.
Mirrors
Mirrors is a 2D nondeterministic esolang with only one instruction.
Grid and matrices
Like in other 2D esolangs, programs in Mirrors are 2D grids, except that every cell is a 4x4 matrix:
[[a,b,c,d],[e,f,g,h],[i,j,k,l],[m,n,o,p]]
All matrix element are real numbers and every row must add up to 1. Matrices in one line are separated by spaces.
The grid extends infinitely rightwards and downwards. The behavior of the IP attempting to cross the top or left edge is the same as that of Nopfunge Solid.
Execution
We first number the four possible directions of the IP: right, up, left, down are 0, 1, 2, 3 respectively. A matrix A has the probability of Ai,j to turn the IP from its current direction i to the direction represented by j.
Command examples
Befunge >: [[1,0,0,0],[1,0,0,0],[1,0,0,0],[1,0,0,0]] (<,v and > can be implemented in similar ways) Befunge ?: [[0.25,0.25,0.25,0.25],[0.25,0.25,0.25,0.25],[0.25,0.25,0.25,0.25],[0.25,0.25,0.25,0.25]]
Computational class
Turing-complete, because it can be trivially translated from Nopfunge Solid.