正在加载图片...
Chapter 4 Data Structure 4.2 Stacks As we observed in the case of lists, a programmer would probably find it advantageous to write procedures that perform these push and pop operations so that the stack could be used as an abstract tool. Note that these procedures should handle such special cases as attempts to pop entries from an empty stack and to push entries onto a full stack. In particular, a complete stack system would probably contain procedures for pushing entries, popping entries, testing for an empty stack, and testing for a full stack. 同我们观察到表中的情况一样,程序员也可以将堆栈编写成 个可以进行进栈和出栈操作的抽象工具。注意,这些过程 应该可以处理诸如试图从空栈中弹出数据,或者将数据压入 个已经填满的堆栈等特殊情况。所以一个完整的堆栈系统 应该包括进栈、出栈、测试堆栈是否空或满的功能。 水什第机语 4-19Chapter 4 Data Structure 计算机专业英语 4-19 As we observed in the case of lists, a programmer would probably find it advantageous to write procedures that perform these push and pop operations so that the stack could be used as an abstract tool. Note that these procedures should handle such special cases as attempts to pop entries from an empty stack and to push entries onto a full stack. In particular, a complete stack system would probably contain procedures for pushing entries, popping entries, testing for an empty stack, and testing for a full stack. 同我们观察到表中的情况一样,程序员也可以将堆栈编写成 一个可以进行进栈和出栈操作的抽象工具。注意,这些过程 应该可以处理诸如试图从空栈中弹出数据,或者将数据压入 一个已经填满的堆栈等特殊情况。所以一个完整的堆栈系统 应该包括进栈、出栈、测试堆栈是否空或满的功能。 4.2 Stacks
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有