简体   繁体   English

构建图灵机按顺序列出所有整数?

[英]Building Turing Machine to list all the integers in order?

我正在学习图灵机,我想知道如何使用图灵机进行所有的int。

Numbers are also a question of encoding. 数字也是编码的问题。

You could use the unary encoding: 您可以使用一元编码:

1 = I
2 = II
3 = III

and so on. 等等。

But you can never list all integers. 但你永远不能列出所有整数。 There are too many. 有太多了。 The band is endless and it takes endless time to use it up. 乐队是无止境的,使用它需要无尽的时间。

You can accept all integers. 你可以接受所有整数。 So if an integer is on the band then you can accept if it is 0-9 for example and reject if there is another letter. 因此,如果一个整数在带上,那么你可以接受它是否为0-9例如,如果有另一个字母则拒绝。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM