Skip to main content

An object-oriented highly flexible brainfuck interpreter.

Project description

brainfuck-interpreter

An object-oriented highly flexible brainfuck interpreter.

Why?

Even though there are probably countless of other options, I've made this because I found other projects were too high-level for me and didn't provide much control over the interpreter. This module, however, allows the developer to access, modify and control every piece of how the brainfuck is evaluated, making this program superior to other projects.

It was also a fun project to work on in general.

Features

  • Object-oriented
  • Easy to use
  • Logging integration
  • Allows streaming of brainfuck code
  • Manual input/output stream control
  • Manual interpreter stepping

Examples

A basic example which should suit most usages of this library:

import brainfuck

bf = '+[----->+++<]>+.---.+++++++..+++.[--->+<]>----.'
print(brainfuck.evaluate(bf))  # hello!

For examples featuring more control over the interpreter, check out the examples directory.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

brainfuck-interpreter-1.0.0.tar.gz (3.1 kB view details)

Uploaded Source

File details

Details for the file brainfuck-interpreter-1.0.0.tar.gz.

File metadata

  • Download URL: brainfuck-interpreter-1.0.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.40.2 CPython/3.8.0

File hashes

Hashes for brainfuck-interpreter-1.0.0.tar.gz
Algorithm Hash digest
SHA256 6059fef0f12628ccd8e2fa66e8b8947af56d79373ae7f0a8a2cd89ae05c2f317
MD5 548083d425a4dcbdaeef58562f9b7434
BLAKE2b-256 c53a80cf25c5068dcf475c52dedceb863fea3ffd62badfa3d7a5406b3a766a7f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page