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.
A Painter Ant
A Painter Ant is an esoteric programming language created by User:Rainwave in 2026. It is a grid-based esolang with a single cursor that has conditional movement and unconditional writing. The name pays homage to Langton's ant, the inspiration for this language.
Language Description
Data Structure
The language operates on an infinite grid. Each cell in the grid holds a color, either black or white. All cells start with the color black.
Ant
The ant is a single cursor placed on the grid at an arbitrary origin cell. The ant can be instructed to move in one of four directions (north, east, south, or west) and manipulate the color of the cell it occupies.
Program
A program consists of a string of instructions. There are ten available instructions:
n: Move the ant north if the cell to the north of the ant has the color black.N: Move the ant north if the cell to the north of the ant has the color white.e: Move the ant east if the cell to the east of the ant has the color black.E: Move the ant east if the cell to the east of the ant has the color white.s: Move the ant south if the cell to the south of the ant has the color black.S: Move the ant south if the cell to the south of the ant has the color white.w: Move the ant west if the cell to the west of the ant has the color black.W: Move the ant west if the cell to the west of the ant has the color white.p: Paint the cell under the ant with the color black.P: Paint the cell under the ant with the color white.
Although there are ten instructions, each belongs to a lowercase–uppercase pair. The lowercase and uppercase instructions in a pair perform the same operation, differing only in the color they correspond to. The lowercase instruction corresponds to the color black, while the uppercase instruction corresponds to the color white.
The entire program runs in an implicit loop, meaning the instruction pointer automatically returns to the first instruction after the final instruction is executed.
Examples
This program creates an ever-growing diamond shape
PnPwPsPe
This program sets up a counter and starts a countdown. After the countdown finishes, the ant will march southwards. The initial value of the counter can be adjusted by changing the number of Pe in the first line.
PePePePePePePePePePePePePePePePePePePePePePePePePePe PEpW ePWsPN EpWSpN WsPN ESpNWePW sss ePwPsPN