I mean yeah but this is javascript. Only 3 phases of transpilation is for noobs.
brainfuck->typescript->es6->via babel->es5->postCss plugins->sass->css->transpiled to react components->transpiled to an Angular 2 project->to webcomponents->transpiled to ArnoldC language->transpiled to a Turing complete Shopify liquid template-> commonjs and browserified->rails sprocket pipeline->then piped to /dev/null
I'd really like to see that. I'm eager to build a small program that takes style offenses like nested ternary operators and replaces them with a still functional brainfuck equivalent, to highlight how anoying that style of programming is to read.
I was surprised to learn that this has got to be one of the only languages which is easier to compile than interpret. When compiled the language reduces to basically a single-register assembly with a one-to-one character-to-line ratio. Bracket branching can be extremely easily implemented with jump labels and `test` + `jnz` statements without having to worry about things like parsing and jump table construction at all.
It's pretty freaking easy to interpret, as well... I implemented an interpreter in Go (which I had never used before) in an hour or so; most of the time spent was learning the two languages (Go and BF).
I should start asking interview candidates to write a BF interpreter...
The not being afraid of going unconventional ways refers to the levels of sauerbraten being stored in octrees. This is quite tough too edit if you are used to 3dsmax and blender. Actually that was too much effort- thus the project never came to be- but the way its stored and accessed, is blazingly fast and effective. One has to admire this skills.
It's really cute how the author added $ to insert a debugging break into the source. Instead of "debugging by printf", which is a bit tedious in brainfuck, this is driving your debugger by editing the source code. Bravo!
I was laughing in a good way, it's always cool to see not only the "thing" but how it was debugged.
As for python, I debug it by adding print() statements. No debugger involved. If there's a way to insert debugger breakpoints in the source, I'm unaware of it.
I recently learned you can do a similar thing with C/C++ too. Programmatically raise a SIGINT when running under gdb, and gdb will intercept that signal, at which point you can step through the code.
I think the best approach for the Brainfuck madness is to write a compiler/transpirer from a high level language (e.g. LOLCODE) to generate Brainfuck code. Then you can write your app in the high level language and show off the generated Brainfuck code.
So delighted to see this :D
I once fail/won with a paper in whitespace. I love the non-traditional programming languages. They're fun, whimsical, and sometimes a nice break.
LOLCode is still my favorite though. I wrote a prime number generator in it for fun :)
61 comments
[ 3.1 ms ] story [ 125 ms ] thread"Combination of Brainfuck with paper mediums for transmission to location for processing, storage, distribution, and archiving of said combinations."
If you made a Brainfuck patent, you need to write me a check.
Still funny though.
brainfuck->typescript->es6->via babel->es5->postCss plugins->sass->css->transpiled to react components->transpiled to an Angular 2 project->to webcomponents->transpiled to ArnoldC language->transpiled to a Turing complete Shopify liquid template-> commonjs and browserified->rails sprocket pipeline->then piped to /dev/null
It's not easy being a Javascript Ninja/Rockstar.
Having reached the lowest level of the machine, they started digging...
I should start asking interview candidates to write a BF interpreter...
The not being afraid of going unconventional ways refers to the levels of sauerbraten being stored in octrees. This is quite tough too edit if you are used to 3dsmax and blender. Actually that was too much effort- thus the project never came to be- but the way its stored and accessed, is blazingly fast and effective. One has to admire this skills.
http://knowyourmeme.com/memes/pretty-cool-guy
As for python, I debug it by adding print() statements. No debugger involved. If there's a way to insert debugger breakpoints in the source, I'm unaware of it.
For POSIX you have `raise(SIGTRAP)` or gcc you have `__builtin_trap()` which actually has some caveats. [1]
[0] https://msdn.microsoft.com/en-us/library/windows/desktop/ms6...
[1] https://stackoverflow.com/questions/173618/is-there-a-portab...
I didn't really expect that
LOLCode is still my favorite though. I wrote a prime number generator in it for fun :)
The language is also Turing complete.
It is possible to use genetic programming (and other approaches) to generate brainfuck programs without an insane amount of effort.
Eventually the resulting program can be processed to be made more efficient.