SebTee / bfInterpreter

This is an interpreter for the esoteric programming language Brainfuck.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Brainfuck Interpreter

This is an interpreter for the esoteric programming language Brainfuck.

Instructions

Compiling

gcc main.cpp Interpreter.cpp Memory.cpp -lstdc++ -o bfInterpreter

You can replace bfInterpreter with any name for the outputted executable file. Make sure to use the correct file name when running the program.

Running a brainfuck program

./bfInterpreter /path/to/file.bf (input to the program)

examples

Hello World

This program outputs the line Hello World!

./bfInterpreter ./examples/HelloWorld.bf
Mandelbrot

This program outputs the Mandelbrot set. This program was written by Erik Bosman.

./bfInterpreter ./examples/mandelbrot.bf
Cat

This program just outputs the input string without changing it.

./bfInterpreter ./examples/cat.bf This text is output!
Hello World Mk.2

This program will also output Hello World!

./bfInterpreter ./examples/cat.bf Hello World!

About

This is an interpreter for the esoteric programming language Brainfuck.

License:MIT License


Languages

Language:C++ 100.0%