Settings

Theme

Show HN: Tru – An Esoteric Language with Brackets

github.com

6 points by stockkid 5 years ago · 2 comments

Reader

stockkidOP 5 years ago

Hi everyone, I wanted to share a language I made that only uses a series of bracket characters. All operations are prefix-free, meaning one can follow another without ambiguity.

The following program prints "Hello, world!"

  (0)(10)(33)(100)(108)(114)(111)(119)(32)(44)(111)(108)(108)(101)(72)>><<[<><>><<>><<]>>><<
The following prints 25th Fibonacci number:

  (1)(25)(1)><>(1)(0)><>(1)>>>>>><<[(0)><>(1)>>>>>><<[>><>(1)><>>><<(0)><>>>><>(1)><><<<>><>>>><>(0)><>>><>(1)>>>>>><<](0)](1)><><><>><>>>><<
fjfaase 5 years ago

I think we should not confuse obfuscation with esoteric. To add some more obfuscation use nested round brackets to indicate the numbers, so () = 0, (()) = 1, ((())) = 2, and so on.

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection