Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Quick and dirty brainfuck interpreter
C
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
Makefile
README.md
main.c

README.md

bf

This is a quick and dirty brainfuck interpreter I wrote in C. It was written in about an hour during a compilers lecture when I felt inspired, and then polished for about another hour.

I was just having fun with C when I wrote this, and decided to try and make the code as compact as I could. Hence some of the weird stylistic choices, such as using an array of function pointers instead of a switch statement.

I'm tempted to refine it futher by removing all conditional branching from the main execution loop by using another array of function pointers for the [ and ] loops. But that'd make the code too unreadable.

Harry.

Something went wrong with that request. Please try again.