自我修改代码的编程语言? [英] Programming language for self-modifying code?
本文介绍了自我修改代码的编程语言?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
- 我最近正在考虑编写自我修改程序,我认为它可能功能强大且有趣.因此,我目前正在寻找一种可以轻松修改程序自己的代码的语言.
- 我了解了 C#(作为一种解决方法)以及在运行时编译和执行代码的能力,但这太令人伤心了.
- 我也在考虑组装.更改正在运行的代码比较容易,但是功能不是很强大(非常原始).
- I am recently thinking about writing self-modifying programs, I think it may be powerful and fun. So I am currently looking for a language that allows modifying a program's own code easily.
- I read about C# (as a way around) and the ability to compile and execute code in runtime, but that is too hurting.
- I am also thinking about assembly. It is easier there to change running code but it is not very powerful (very raw).
您能建议一种功能强大的语言或功能来支持在运行时修改代码吗?
那是我在运行时修改代码的意思:
That what I mean by modifying code in runtime:
Start:
a=10,b=20,c=0;
label1: c=a+b;
....
label1= c=a*b;
goto label1;
,并且可能正在建立说明列表:
and may be building a list of instructions:
code1.add(c=a+b);
code1.add(c=c*(c-1));
code1. execute();
推荐答案
Malbolge 是开始的好地方.每条指令都是可以自我修改的,而且玩起来很有趣(*).
Malbolge would be a good place to start. Every instruction is self-modifying, and it's a lot of fun(*) to play with.
(*)免责声明:可能实际上并不有趣.
(*) Disclaimer: May not actually be fun.
这篇关于自我修改代码的编程语言?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文