Skip to content

Headorteil/iiiEsotericLanguage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 

Repository files navigation

iii Esoteric Language

I made this python esoteric language interpreter for my esoteric language : iii which have the particularity to have his programms only composed by the character i.

This interpreter use a BrainFuck python interpreter and the synthax of iii and BrainFuck are in bijection, so whatewer can do BrainFuck, iii cans also do.

Also to note : BrainFuck is turing complete, so iii is. That means, with an infinite amount of ressources, any computable programe can be written in iii.

PS : Maybe the programms files of iii are a little bit heavy ^^ (A programm which print "Hello World!" is written with a file that contains 11394260736961616017478696325142642241587016089942641935756584435039981423330228839638374655156139739 i), but i implemented that a way you can play with the number of i and not necessarly the file itself.

Because of that, I implemented a function which convert your iii codes to binary codes (with iii extension) wich is a really compressed version of iii but which keep all the information of a iii code.

By the way, this method allow us to also compress BrainFuck file

usage: iiiEsotericHeadorteil.py [-h] [-a A] [-n N] [-p P] [-o O] [-b B] [-f F]
                                [-e] [-d] [-c] [-w] [-x]

iii Encoder/Decoder/Executer (deals with BrainFuck)

optional arguments:
  -h, --help  show this help message and exit
  -a A        Specify/Print the string of your BrainFuck program (input or
              output) give this option "yes" if it is use for an output
  -n N        Specify/Print the number of i your programm would contain (if
              you don'precise this option in -c mode, be careful, iii
              programms can be really huge and you may have an overflow error)
              (input or output) give this option "yes" if it is use for an
              output
  -p P        Specify the path of your iii file (input or output)
  -o O        Specify the path of your BrainFuck file(input or output)
  -b B        Specify the input of your iii programm
  -f F        Specify the iii binary file
  -e          Execute your programm
  -d          Convert your iii program to BrainFuck
  -c          Convert your BrainFuck program to iii
  -w          Convert your iii file/number to a iii binary
  -x          Convert your iii binary to a iii file/number

Examples :
$ ./iiiEsotericHeadorteil.py -c -a"++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>." -n"yes"
$ ./iiiEsotericHeadorteil.py -d -n11394260736961616017478696325142642241587016089942641935756584435039981423330228839638374655156139739 -o"./output.bf"
$ ./iiiEsotericHeadorteil.py -e -n11394260736961616017478696325142642241587016089942641935756584435039981423330228839638374655156139739
$ ./iiiEsotericHeadorteil.py -e -n12250030 -b"yay"
$ ./iiiEsotericHeadorteil.py -w -p"./input.txt" -f"./output.iii"
$ ./iiiEsotericHeadorteil.py -x -f"./input.iii" -p"output.txt"

A little example :

iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii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iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii

is a iii program which prints the 2 firsts characters of the argument you give to it.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages