Moed/Examples

From Esolang
Jump to navigation Jump to search

Back to Moed

Hello world

(&Hello, world!)@
("Hello, world!)>{=@ `,}= <

Truth machine

=_={@.}#`
:.=

Cat

=@&`,

String sum

>&=`|\=+ =`<$.@

Display color

This program displays a color using a string sum of the strings "red", "green", and "blue", divides by 100 and then uses it as a jump argument

>&=`|\=+ =`<$554**\/~.~Jjjj1488**-488**488****-00~|~@j1488**-00~|~@j1488**-488***00~|~@

Random grayscale image

5>{5>{1~?~488***-~.~::488***+488***+2;2;~|~={>"=2} `1\-}= <
$={>"=2} `1\-}= <
@

ASCII compressor

Takes an ASCII string and compresses it into a single Unicode character

&={@,$} `\488***+

Can be used as a fortune generator with your name.

With my name it gives .

This thing

0>{:J&_j?_j@
=@ `'0\-J:._j1+2\%}=
<

Base n to base 10 converter

#00~|~&$#&$0>{\1\-:00~^~^&'0\-*2;+={>"=2$}\`\}= <
.@
Format input like this: b,l,ddddd... where b is the base, l is the length of the source number, and d is the number, , means any non-numeric character

Brainfuck interpreter

This section is still a work in progress. It may be changed in the future.
=_( data coordinates:
_x,y
_ ,0 - tape
_ ,1 - program
_ ,2 - stack
_0,3 - tape pointer
_1,3 - program pointer
_2,3 - stack pointer
_)0>&={+1~|~1;1} =`<$$
13~^~:1~^~\1+13~|~
        :   =_ =0 =$ =`<$$ @
>=_ =`<$:'+-=_ =0 =$ =`<$$ 03~^~:0~^~1+884**\%\0~|~  1
>=_ =`<$:'--=_ =0 =$ =`<$$ 03~^~:0~^~1\-884**\%\0~|~ 1
>=_ =`<$:'>-=_ =0 =$ =`<$$ 03~^~1+03~|~              1
>=_ =`<$:'<-=_ =0 =$ =`<$$ 03~^~1\-03~|~             1
>=_ =`<$:'.-=_ =0 =$ =`<$$ 0~^~,                     1
>=_ =`<$:',-=_ =0 =$ =`<$$ ?1;0~|~                   1
>=_ =`<$:'[-=_ =0 =$ =`<$$ 03~^~0~|~={{"1` {13"}=$` {$1+2"}=-['$` {$1\-2"}=-]'~|~31+1~^~31
}
$} `1
>=_ =`<$:']-=_ =0 =$ =`<$$ 1
>      $$=