{"id":20668920,"url":"https://github.com/guidanoli/lua-bf","last_synced_at":"2026-05-20T16:39:40.175Z","repository":{"id":67679103,"uuid":"222030986","full_name":"guidanoli/lua-bf","owner":"guidanoli","description":"Brainfuck language interpreter in Lua","archived":false,"fork":false,"pushed_at":"2020-07-24T18:02:28.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-17T13:29:28.164Z","etag":null,"topics":["brainfuck","lua"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/guidanoli.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-11-16T01:40:46.000Z","updated_at":"2020-07-24T18:02:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"65e0713d-f21a-48fe-bcdc-582f028eee36","html_url":"https://github.com/guidanoli/lua-bf","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidanoli%2Flua-bf","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidanoli%2Flua-bf/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidanoli%2Flua-bf/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidanoli%2Flua-bf/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/guidanoli","download_url":"https://codeload.github.com/guidanoli/lua-bf/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242873750,"owners_count":20199294,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["brainfuck","lua"],"created_at":"2024-11-16T20:12:11.659Z","updated_at":"2026-05-20T16:39:35.146Z","avatar_url":"https://github.com/guidanoli.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Brainfuck Language Interpreter in Lua\n\nBrainfuck is an esoteric language. A strangely simple esoteric language. That means it's not really useful for day-to-day challenges, but for having fun with building a very simple compiler/interpreter.\n\nBrainfuck works much like a Turing Machine: a (nearly infinite) tape, a head, and a state register. Plus input and output operators and loops. To read more about brainfuck, check out its article on Esolang [here](https://esolangs.org/wiki/Brainfuck)!\n\nI chose Lua mainly because it handles hash tables natively, which really helps the compiler scalability. Plus Lua is really lightweight, unlike Python.\n\n## Running\n\nSimply run the lua script on your terminal...\n\n```bash\nlua bf.lua\n```\n\n...and type/paste the brainfuck code and then escape input (Ctrl+D on Unix, Ctrl+Z on Windows).\n...if requested input, type and escape ever after each character. Cease input by escaping twice.\n\nHere is a demo of the interpreter running [this script](http://www.hevanet.com/cristofd/brainfuck/wc.b) by [daniel b cristofani](http://www.hevanet.com/cristofd/brainfuck/), which counts lines, words and bytes of input:\n\n```\n\u003e\u003e\u003e+\u003e\u003e\u003e\u003e\u003e+\u003e\u003e+\u003e\u003e+[\u003c\u003c],[\n    -[-[-[-[-[-[-[-[\u003c+\u003e-[\u003e+\u003c-[\u003e-\u003c-[-[-[\u003c++[\u003c++++++\u003e-]\u003c\n        [\u003e\u003e[-\u003c]\u003c[\u003e]\u003c-]\u003e\u003e[\u003c+\u003e-[\u003c-\u003e[-]]]]]]]]]]]]]]]]\n    \u003c[-\u003c\u003c[-]+\u003e]\u003c\u003c[\u003e\u003e\u003e\u003e\u003e\u003e+\u003c\u003c\u003c\u003c\u003c\u003c-]\u003e[\u003e]\u003e\u003e\u003e\u003e\u003e\u003e\u003e+\u003e[\n        \u003c+[\n            \u003e+++++++++\u003c-[\u003e-\u003c-]++\u003e[\u003c+++++++\u003e-[\u003c-\u003e-]+[+\u003e\u003e\u003e\u003e\u003e\u003e]]\n            \u003c[\u003e+\u003c-]\u003e[\u003e\u003e\u003e\u003e\u003e++\u003e[-]]+\u003c\n        ]\u003e[-\u003c\u003c\u003c\u003c\u003c\u003c]\u003e\u003e\u003e\u003e\n    ],\n]+\u003c++\u003e\u003e\u003e[[+++++\u003e\u003e\u003e\u003e\u003e\u003e]\u003c+\u003e+[[\u003c++++++++\u003e-]\u003c.\u003c\u003c\u003c\u003c\u003c]\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e]\ni would like a cup of tea\t0\t7\t25\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguidanoli%2Flua-bf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fguidanoli%2Flua-bf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguidanoli%2Flua-bf/lists"}