Skip to main content
Brainfk

=======

Brainfk is a Python package that provides an interpreter for the Brainfuck programming language. It allows you to execute Brainfuck code and see the output.

Features
--------

- Simple and intuitive interface to run Brainfuck code.
- Supports reading Brainfuck code from a file or direct input.
- Handles the basic Brainfuck commands: +, -, <, >, ., ,, [, ].
- Supports nested loops in Brainfuck code.

Installation
------------

You can install Brainfk using pip:

```
pip install brainfk
```


Brainfk requires Python 3.7 or higher.

Usage
-----

You can run the Brainfuck interpreter by executing the `brainfk` command followed by the path to a file containing Brainfuck code or by providing the code directly as input.

To execute Brainfuck code from a file:

```
brainfk path/to/brainfuck_file.bf
```

To provide Brainfuck code as input:

```
brainfk
```

The interpreter will prompt you to enter the Brainfuck code. Type or paste the code, and press Enter.

Examples
--------

Here are some examples to demonstrate how to use Brainfk:

1. Execute Brainfuck code from a file:

```
brainfk examples/hello_world.bf
```

2. Execute Brainfuck code by providing input:

```
brainfk
```

Enter the Brainfuck code: `,.[.,]`

Enter the input: `Hello, Brainfuck!`

Development and Contributing
----------------------------

If you would like to contribute to Brainfk, feel free to open pull requests for bug fixes, enhancements, or new features. Please ensure that your code follows the existing coding style and includes appropriate tests.

License
-------

This project is licensed under the MIT License. See the LICENSE file for details.

Release files for brainfk 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for brainfk 0.0.2
File Size Uploaded
brainfk-0.0.2.tar.gz 3.2 kB Details

Release files / brainfk-0.0.2.tar.gz

Download URL brainfk-0.0.2.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
c134d884bfdd3b898239079fee15f0f3434971fdc55b5dd6cec687bac7b88ce9
BLAKE2b-256 checksum
How to use checksums
43a161e36c2fb4950093a5e4ef1c4c6a6a88088460380391470e4186c10ce956
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.11

Release history Release notifications | RSS feed

This release

0.0.2 This release

1 release file

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page