想象一下可以修改子程序的返回值!
Imagine being able to modify the return value of your subroutine!
子程序、引用和数据结构。
子程序有两种形式——过程或函数。
Subprograms occur in one of two forms — procedures or functions.
子程序的其余部分实现简单的震动检测算法。
The remainder of the subroutine is the implementation of the simple shake-detection algorithm.
这与调用所有其它子程序的“主例程”类似。
This is analogous to a "main routine" which invokes all other subroutines.
清单5 . matchwords子程序。
本文使用的示例程序是一个投骰子程序。
The sample program used for this article is a die-rolling program.
让我们来看一看这个子程序并了解一下其工作原理。
Let's take a look at the subroutine and describe how it works.
如果使用子程序的话,它不能是递归的。
设置了子程序后,我们将快速转入简短的主程序逻辑。
With our subroutines set up, we move quickly into the short main program logic.
这种模式通常用于全局变量访问、分支以及子程序调用。
This mode is often used for global variable access, branching, and subroutine calls.
Figure5显示了例子程序的输出结果。
子程序是在一段程序中可以被重用的部分,就像活字那样。
A subroutine is a part of a program that can be re-used, just like movable type.
程序员喜欢使用那些很好地进行了优化,容易使用的子程序。
Programmers like well-optimized, atomic subroutines that are ready to use.
stack区域用于子程序返回地址,也用于存储自动数据。
The stack region is used for subroutine return addresses, as well as to store automatic data.
Pie模块的标绘子程序期望获得一批数组(标签和数据值)。
The plot subroutine of the GD::Pie module expects an array of arrays (labels and data values).
如果有一个或多个星号,子程序将继续执行处理来创建正则表达式。
If one or more asterisks are present, the subroutine will continue its processing to create the regular expressions.
这样做使增加互斥代码时只需要在一个子程序中进行改动。
This way, the change to add mutex code only has to happen in one place.
controller子程序也包含同客户端软件交互的用户接口。
The Controller subprogram also contains the user interface to interact with the client software.
这意味着我们将开始一个子程序来创建我们的界面的基石。
This means we will start a subroutine to create the building blocks of our interface.
接下来,我将介绍另外的一个子程序:创建动态GUI元素。
Next, I'll talk about the other sub-process, creating dynamic GUI elements.
一个可以通过网络存取的掷骰子程序在许多方面适合作为示例程序。
A network-accessible die roller has many features that make it suitable as a demonstration program.
子程序这章主要针对新的语法(原型和属性),以及左值属性(5.6.0)。
The subroutines chapter covers new syntax (prototypes and attributes), plus the brand new lvalue attribute (as of 5.6.0).
在NLTK中使用了一些专门的键,不同的键由不同的子程序包所使用。
A few special keys are used in NLTK, different ones by the various subpackages.
pthread_create()子程序使用线程参数返回新的线程ID。
The pthread_create() subroutine returns the new thread ID using a thread argument.
这一选项类似于上一个选项,所有组件被整合成一个应用程序中的子程序。
This option is similar to the last option in that all the components are integrated as sub-programs in a single application.
在这个状态下代码会在事件发生的同时运行一个子程序来检查答案并显示下一道问题。
In the next state, the script will run a subroutine associated with the event to check the answer and display the next multiple question.
这些都显示出了应用服务模块的重要性,不管是在SOA服务还是在普通的子程序中。
This brings out the importance of application service modules, either as SOA services or simple subroutines.
这些都显示出了应用服务模块的重要性,不管是在SOA服务还是在普通的子程序中。
This brings out the importance of application service modules, either as SOA services or simple subroutines.
应用推荐