whatlang-interpreter
Version:
Interpreter for WhatLang 2024, a stack-based esolang
22 lines (16 loc) • 594 B
Markdown
# whatlang-interpreter
[](https://www.npmjs.com/package/whatlang-interpreter)
Fork of the core part of the [original](https://github.com/YufangProbably/koishi-plugins/tree/main/plugins/whatlang) interpreter for [WhatLang](https://esolangs.org/wiki/WhatLang) (2024), as a standalone package
## Usage
~~~shell
what your_code.what
~~~
~~~typescript
import { eval_what, default_var_dict } from "whatlang-interpreter"
await eval_what(
"114 514+.",
[[]],
{ ...default_var_dict },
console.log,
) // Prints and returns: 628
~~~