From 001472b9bd0570e7a79b262f31c3626aa8ea1532 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:00 +0100 Subject: [PATCH 01/19] Create README.md --- book/languages/malbolge/README.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/README.md diff --git a/book/languages/malbolge/README.md b/book/languages/malbolge/README.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/README.md @@ -0,0 +1 @@ + From 13270ad6b8a206071dd11f29d5a6d31958981787 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:13 +0100 Subject: [PATCH 02/19] Create advantages.md --- book/languages/malbolge/advantages.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/advantages.md diff --git a/book/languages/malbolge/advantages.md b/book/languages/malbolge/advantages.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/advantages.md @@ -0,0 +1 @@ + From a8bc53c5637e67043cb0693248b896c9748d6ac7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:22 +0100 Subject: [PATCH 03/19] Create conclusion.md --- book/languages/malbolge/conclusion.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/conclusion.md diff --git a/book/languages/malbolge/conclusion.md b/book/languages/malbolge/conclusion.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/conclusion.md @@ -0,0 +1 @@ + From 3eaa7383d5c4ec01620ab6acdc326681e08a8ece Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:31 +0100 Subject: [PATCH 04/19] Create disadvantages.md --- book/languages/malbolge/disadvantages.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/disadvantages.md diff --git a/book/languages/malbolge/disadvantages.md b/book/languages/malbolge/disadvantages.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/disadvantages.md @@ -0,0 +1 @@ + From 8509e62958e5b10682a86cd241caa747055981f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:41 +0100 Subject: [PATCH 05/19] Create history.md --- book/languages/malbolge/history.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/history.md diff --git a/book/languages/malbolge/history.md b/book/languages/malbolge/history.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/history.md @@ -0,0 +1 @@ + From dacbf389747e3da88e61d6f17997eaf08e183396 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:48:49 +0100 Subject: [PATCH 06/19] Create intro.md --- book/languages/malbolge/intro.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/intro.md diff --git a/book/languages/malbolge/intro.md b/book/languages/malbolge/intro.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/intro.md @@ -0,0 +1 @@ + From 11fb01cdfc26725eb0dff23e527dec3b981a7d56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:49:00 +0100 Subject: [PATCH 07/19] Create misc.md --- book/languages/malbolge/misc.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 book/languages/malbolge/misc.md diff --git a/book/languages/malbolge/misc.md b/book/languages/malbolge/misc.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/book/languages/malbolge/misc.md @@ -0,0 +1 @@ + From 420b82317fa0a465e01ce6d34cc1827c6bd23c50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:49:38 +0100 Subject: [PATCH 08/19] Update README.md --- book/languages/malbolge/README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/book/languages/malbolge/README.md b/book/languages/malbolge/README.md index 8b13789..dd30562 100644 --- a/book/languages/malbolge/README.md +++ b/book/languages/malbolge/README.md @@ -1 +1,6 @@ +# Welcome +> This chapter has been authored by Krzysztof Szewczyk "Παλαιολόγος". + +Welcome to the Malbolge chapter! I'd like to let you know a bit more about +this amazingly difficult language. From b0b1ef04768bc62490c1bb3750478cd99d6fef6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:56:13 +0100 Subject: [PATCH 09/19] Update advantages.md --- book/languages/malbolge/advantages.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/book/languages/malbolge/advantages.md b/book/languages/malbolge/advantages.md index 8b13789..14bcf32 100644 --- a/book/languages/malbolge/advantages.md +++ b/book/languages/malbolge/advantages.md @@ -1 +1,18 @@ +# Advantages +Generally speaking, currently, Brainfuck is a joke language. Therefore, it's not very efficient, nor easy to write. + +First of all, like all esoteric languages, it's a really good exercise for your brain! If Malbolge was Go of programming, Brainfuck +would be chess, and Assembly would be checkers. + +Malbolge is really simple! It won't take long to learn it. + +There were attempts to use Malbolge in a few real world cases, including encryption! Just think what if some critical encryption +algo would be implemented in Malbolge, and it would be **very** fast because of it's simplicity - it would take long, long time +to discover how it's implemented. + +Finally, Malbolge is not language that machines can eaisly generate, therefore it's really secure language. Imagine writing +Malbolge program displaying some kind header (copyright, program name, etc.). No one probably wouldn't even attempt to touch +the code! + +There are a few Malbolge hackmes, that weren't solved **to this day**! From 10a73efd1c61382086ae450bb1101ad43b5825d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:56:45 +0100 Subject: [PATCH 10/19] This is what happens when you copy contents of one chapter to another --- book/languages/malbolge/advantages.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book/languages/malbolge/advantages.md b/book/languages/malbolge/advantages.md index 14bcf32..4f5a0a8 100644 --- a/book/languages/malbolge/advantages.md +++ b/book/languages/malbolge/advantages.md @@ -1,6 +1,6 @@ # Advantages -Generally speaking, currently, Brainfuck is a joke language. Therefore, it's not very efficient, nor easy to write. +Generally speaking, currently, Malbolge is a joke language. Therefore, it's not very efficient, nor easy to write. First of all, like all esoteric languages, it's a really good exercise for your brain! If Malbolge was Go of programming, Brainfuck would be chess, and Assembly would be checkers. From 45643585e89a23bd9aa0fc5692b6e7b26fbdc913 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 10:59:59 +0100 Subject: [PATCH 11/19] Update conclusion.md --- book/languages/malbolge/conclusion.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/book/languages/malbolge/conclusion.md b/book/languages/malbolge/conclusion.md index 8b13789..6cb8a3f 100644 --- a/book/languages/malbolge/conclusion.md +++ b/book/languages/malbolge/conclusion.md @@ -1 +1,13 @@ +# Conclusion +Malbolge was meant to be a joke language, but fiddling with it to find real world use case is **not** waste of time +(unlike brainfuck), due to cryptographical possibilities! + +Thinking about Malbolge in real terms is a bit risky, it's always quicker and easier to program other languages. Malbolge +doesn't really differ in problem it's solving with other esoterIc languages, it was already mentioned in Brainfuck chapter, + +Like with most esoteric languages, to play around with Malbolge you need basically no experience - basic knowledge of maths and +decent imagination are going to be sufficient. + +Summing around disadvantages and advantages - Malbolge is impractical as heck and it's dangerous to consider Malbolge real +language. But there's nothing bad in playing with it, trying to find real world use cases! From 7a74c45fde09bccf8856cc224bbc81ae9cf7effe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:00:21 +0100 Subject: [PATCH 12/19] Update conclusion.md From 64efa15ce1380629cca6a23eab28de9a67b5b721 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:02:53 +0100 Subject: [PATCH 13/19] Update disadvantages.md --- book/languages/malbolge/disadvantages.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/book/languages/malbolge/disadvantages.md b/book/languages/malbolge/disadvantages.md index 8b13789..161f84f 100644 --- a/book/languages/malbolge/disadvantages.md +++ b/book/languages/malbolge/disadvantages.md @@ -1 +1,10 @@ +# Disadvantages +Malbolge is esoteric language. It was created as a joke. There are a few so-called Brainfuck hackers around, but being honest, +You can't earn a living programming in Malbolge these times. + +Malbolge is way too impractical to be using language in real-world cases (even more than Brainfuck!). Developers would cost way +too much and work really inefficiently. Albeit low abstraction level, Malbolge is memory and CPU time inefficient, +so it's not very viable to write anything in bare Malbolge and you'd be better off by using some other language. + +Finally, the language is really bounded - I/O is limited to console input and output, greatly reducing usability. From ca0832113e5008859af99cc6a28e3d9e59ea930a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:03:48 +0100 Subject: [PATCH 14/19] Oh, repetitions, devil's kith and kin --- book/languages/brainfuck/disadvantages.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book/languages/brainfuck/disadvantages.md b/book/languages/brainfuck/disadvantages.md index e373bcf..9a9108c 100644 --- a/book/languages/brainfuck/disadvantages.md +++ b/book/languages/brainfuck/disadvantages.md @@ -8,4 +8,4 @@ inefficiently. Albeit low abstraction level, Brainfuck is memory and CPU time in so it's not very viable to write anything in bare Brainfuck and you'd be better off by using some kind of Brainfuck assembler, or HLL to brainfuck compiler, but none of the listed can beat pure C implementation instead of Brainfuck one. -Finally, the language is a bit limited - I/O is limited to console input and output, greatly reducing use cases. +Finally, the language is a bit constrained - I/O is limited to console input and output, greatly reducing use cases. From ea98b368d63f90bde6c11690a8a53a604cb4d7d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:31:59 +0100 Subject: [PATCH 15/19] Update history.md --- book/languages/malbolge/history.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/book/languages/malbolge/history.md b/book/languages/malbolge/history.md index 8b13789..0d60dfd 100644 --- a/book/languages/malbolge/history.md +++ b/book/languages/malbolge/history.md @@ -1 +1,14 @@ +# History +Malbolge was invented by Ben Olmstead back in 1998. First Malbolge program was written in 2000, but it wasn't written by human - it +was generated by a beam search algorithm implemented in Lisp. + +Later, Lou Scheffer posted a few of his works regarding Malbolge and provided a `cat`-like to copy its input to its output. He also +mirrored the original interpreter and specification after the original site went down, and offered a general strategy of writing +programs in Malbolge as well as some thoughts on its Turing-completeness. + +Olmstead believed Malbolge to be a linear bounded automaton. There is a discussion about whether one can implement sensible loops +in Malbolge, it took many years before the first non-terminating program was introduced. + +Hisashi Iizawa proposed first "99 bottles of beer" application in 2005. He also proposed a guide for programming in Malbolge +regarding it's usefulness software protection. From ac833bd5d3c9fa2fd68781e004f3f98b07e6bfbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:44:27 +0100 Subject: [PATCH 16/19] Update intro.md --- book/languages/malbolge/intro.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/book/languages/malbolge/intro.md b/book/languages/malbolge/intro.md index 8b13789..faa0ca8 100644 --- a/book/languages/malbolge/intro.md +++ b/book/languages/malbolge/intro.md @@ -1 +1,26 @@ + +# Introduction + +Malbolge is one of the most popular esoteric programming languages, named after the eighth circle of hell in Dante's Inferno, the +Malebolge. + +Malbolge was specifically designed to hurt. It's almost impossible to use, because of crazy operation, self encrypting code and base-three arithmetic. It's way more difficult than other esoteric languages (such as Brainfuck), but takes this difficultness to the extreme. Despite this design, it is possible to write useful Malbolge programs. Malbolge is **not** Turing complete, there was attempt to create Turing complete variant of Malbolge, named Malbogle Unshackled. + +Classic "Hello, world!" program looks bizzare in Malbolge: + +```malbolge +(=<`#9]~6ZY32Vx/4Rs+0No-&Jk)"Fh}|Bcy?`=*z]Kw%oG4UUS0/@-ejc(:'8dc +``` + +Technically speaking, Malbolge is machine code for so called Malbolge Virtual Machine. It has three registers - `a`, `c`, and `d`. +When a program starts, the value of all three registers is zero. It doesn't support stack and indefinite memory access out of the +box either. The virtual machine has 59,049 memory locations that can each hold a ten-trit ternary number, making memory access +limited consequently removing possibility of Turing completness. There were attempts to prove Malbolge Unshackled Turing +completness. [Brainfuck interpreter in Malbolge Unshackled](https://github.com/KrzysztofSzewczyk/Brainfuck.MB) was written to do +so. It can be proven using simulation way (which was described in Brainfuck chapter). + +Malbolge is an amazingly difficult language. One needs still to understand where it would be more suitable, and where it doesn't +particularly excel at. + + From 3cbed6e73aff8ba4f53f6faf30da15cf0b7083d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:44:39 +0100 Subject: [PATCH 17/19] No misc! --- book/languages/malbolge/misc.md | 1 - 1 file changed, 1 deletion(-) delete mode 100644 book/languages/malbolge/misc.md diff --git a/book/languages/malbolge/misc.md b/book/languages/malbolge/misc.md deleted file mode 100644 index 8b13789..0000000 --- a/book/languages/malbolge/misc.md +++ /dev/null @@ -1 +0,0 @@ - From ba9641701c09164dbfc0111748615929f57a8475 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:45:34 +0100 Subject: [PATCH 18/19] Add malbolge to summary --- book/SUMMARY.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/book/SUMMARY.md b/book/SUMMARY.md index 2670aa3..0be88d1 100644 --- a/book/SUMMARY.md +++ b/book/SUMMARY.md @@ -146,6 +146,18 @@ * [Conclusion](languages/brainfuck/conclusion.md) * [Some interesting facts](languages/brainfuck/misc.md) + +* [Malbolge](languages/malbolge/README.md) + + * [Introduction](languages/malbolge/intro.md) + + * [History](languages/malbolge/history.md) + + * [Advantages](languages/malbolge/advantages.md) + + * [Disadvantages](languages/malbolge/disadvantages.md) + + * [Conclusion](languages/malbolge/conclusion.md) ## End From 5abc4383212de55de7db3ac0705567d5965f1832 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=A0=CE=B1=CE=BB=CE=B1=CE=B9=CE=BF=CE=BB=CF=8C=CE=B3?= =?UTF-8?q?=CE=BF=CF=82?= Date: Tue, 19 Feb 2019 11:49:30 +0100 Subject: [PATCH 19/19] I hate this linter --- book/languages/malbolge/intro.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/book/languages/malbolge/intro.md b/book/languages/malbolge/intro.md index faa0ca8..2ae0622 100644 --- a/book/languages/malbolge/intro.md +++ b/book/languages/malbolge/intro.md @@ -1,11 +1,13 @@ - # Introduction Malbolge is one of the most popular esoteric programming languages, named after the eighth circle of hell in Dante's Inferno, the Malebolge. -Malbolge was specifically designed to hurt. It's almost impossible to use, because of crazy operation, self encrypting code and base-three arithmetic. It's way more difficult than other esoteric languages (such as Brainfuck), but takes this difficultness to the extreme. Despite this design, it is possible to write useful Malbolge programs. Malbolge is **not** Turing complete, there was attempt to create Turing complete variant of Malbolge, named Malbogle Unshackled. +Malbolge was specifically designed to hurt. It's almost impossible to use, because of crazy operation, self encrypting code and +base-three arithmetic. It's way more difficult than other esoteric languages (such as Brainfuck), but takes this difficultness to +the extreme. Despite this design, it is possible to write useful Malbolge programs. Malbolge is **not** Turing complete, there was +attempt to create Turing complete variant of Malbolge, named Malbogle Unshackled. Classic "Hello, world!" program looks bizzare in Malbolge: @@ -13,14 +15,12 @@ Classic "Hello, world!" program looks bizzare in Malbolge: (=<`#9]~6ZY32Vx/4Rs+0No-&Jk)"Fh}|Bcy?`=*z]Kw%oG4UUS0/@-ejc(:'8dc ``` -Technically speaking, Malbolge is machine code for so called Malbolge Virtual Machine. It has three registers - `a`, `c`, and `d`. -When a program starts, the value of all three registers is zero. It doesn't support stack and indefinite memory access out of the -box either. The virtual machine has 59,049 memory locations that can each hold a ten-trit ternary number, making memory access -limited consequently removing possibility of Turing completness. There were attempts to prove Malbolge Unshackled Turing -completness. [Brainfuck interpreter in Malbolge Unshackled](https://github.com/KrzysztofSzewczyk/Brainfuck.MB) was written to do +Technically speaking, Malbolge is machine code for so called Malbolge Virtual Machine. It has three registers - `a`, `c`, and `d`. +When a program starts, the value of all three registers is zero. It doesn't support stack and indefinite memory access out of the +box either. The virtual machine has 59,049 memory locations that can each hold a ten-trit ternary number, making memory access +limited consequently removing possibility of Turing completness. There were attempts to prove Malbolge Unshackled Turing +completness. [Brainfuck interpreter in Malbolge Unshackled](https://github.com/KrzysztofSzewczyk/Brainfuck.MB) was written to do so. It can be proven using simulation way (which was described in Brainfuck chapter). Malbolge is an amazingly difficult language. One needs still to understand where it would be more suitable, and where it doesn't particularly excel at. - -