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.

Truthy Narcissus

From Esolang
Jump to navigation Jump to search

Truthy Narcissus is designed by PSTF. It's a successor of Narcissus.

Every program in this esolang reads input. If the input is the same as the source code, infinitely print 1, otherwise 0 once.

Example Programs

Truth Machine

1

Interpreter

Python

import sys
code=open(sys.argv[1]).read()
x=sys.stdin.read()
if x == code:
    while True:
        print(1)
else:
    print(0)

See Also

Categories