input hello world or else:

From Esolang
Jump to navigation Jump to search

input hello world or else: is a joke esolang created by User:Ractangle when he was looking at his IT computer desktop and found this file

Syntax

if the command is this:

Hello world

it prints Hello world

else print

grrrrrrrrr

Implementations

Python

print("Hello world")if input()=="Hello world"else print("grrrrrrrrr")

Shorter

print({(x:="Hello world"):x}.get(input(),"grrrrrrrrr"))

Lua

print(io.read():match"^Hello world$"or"grrrrrrrrr")

>|<>|<

>|<, ((?<>/-/(?<?=Hello world<>(Hello world)(grrrrrrrrr))

Note that this if it contains "Hello world" outputs "Hello world", even if it has other things, like "jskljdhwefjkashdjf hakjsd hfashdkfasdfjash kdHello worldkdalsjdl aksdo wakjs ndkawhksdbn a.ls dsk daj" else, grrrrrrrr

See also