4 ms·
I started writing a simple parser/interpreter to convert a C-like language to brainfuck[1]. Simple sample code with a loop at [2] and result code [3] I never q
by qixxiq 13y ago
I started writing a simple parser/interpreter to convert a C-like language to brainfuck[1]. Simple sample code with a loop at [2] and result code [3]
I never quite got around to functions, but there is basic support for arithmetic, for loops and rand()
[1] https://github.com/qix/c2brainfuck https://github.com/qix/c2brainfuck
[2] https://github.com/qix/c2brainfuck/blob/master/samples/beer.c https://github.com/qix/c2brainfuck/blob/master/samples/beer....
[3] https://github.com/qix/c2brainfuck/blob/master/samples/beer.bf https://github.com/qix/c2brainfuck/blob/master/samples/beer....