一个互动的脑力翻译

ibf的Python项目详细描述


互动大脑

一个用bython写的互动式大脑翻译。为什么不?

要从源代码安装,必须首先将bython源代码构建到python包中:

$ make build

然后,移动到python文件夹,并运行安装脚本:

$ cd python
$ sudo -H pip3 install .

安装后,使用ibf命令运行交互式会话:

$ ibf 
Interactive BrainFuck - ibf v0.1

ibf is licensed under the permissive MIT license. Full license and
copyright information is available at the project's GitHub repository.

[Input] +[------->++<]>-.------------.--[--->+<]>--.+.+++[->+++<]>.+++++++++++++.[-->+++++<]>+++.[-->+++++++<]>.++.---.------------.-[--->+<]>----.+++[->+++<]>++.--[--->+<]>--.+.-----------.+++++.-------------.--[--->+<]>-.-----.+++.>++++++++++.
master procrastinator

你输入的所有东西都被解释为脑残代码,除了以下 保留关键字:

CommandDescription
tapePrints the current status of the tape (data cells), with the current cell in bold
posPrints the current position on the tape
quitQuits the session
run <file>Run code from a file

你也可以运行预先编写好的大脑操代码,或者作为一个独立的程序,或者 在交互式会话中:

$ ibf test.bf
Hello World!
$ ibf 
Interactive BrainFuck - ibf v0.1

ibf is licensed under the permissive MIT license. Full license and
copyright information is available at the project's GitHub repository.

[Input] run test.bf
Hello World!

run命令始终运行程序inline,即代码在 当前磁带和当前磁带位置作为起始位置。因此, 运行程序后,您可以检查磁带的最终状态:

[Input] tape
 0 1  2   3  4  5  6 7 8
 0 0 72 100 87 33 10 0 0

有关更多帮助,请键入ibf -h,或通过运行man ibf查看手册页。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
HTTP标头的java InputStream未终止   java测试SpringWebListener   具有定义的替换编号Java的regex ReplaceAll   在java中使用contains()方法   java在选择查询中使用JoinColumn字段   具有用户的java Start-stop demon不是以给定用户启动   java glBufferData生成GL\u无效\u操作   java中循环代码的循环   Java位无符号移位(>>>>)会产生奇怪的结果   java HQL使用点分隔符从select获取结果   条纹、弹簧、玩耍(或?):使用哪种高性能Java框架?   广播接收机中的java停止服务   java回收器视图占据整个屏幕。不在上面显示我的UI元素   java使MySQL查询更快   java MappedByteBuffer查询   java递归算法问题