The Fundamentals of Computer Software
Data Structure
Exercises
Multiple choices.
The attributes of the stack are ( A ).
A. FIFO??????????????????????? B. LIFO
C. queue???????????????????? D. built into their circuitry
Queues that occur everyday life can be seen ( ABCD ).
A. in an emergency room of a hospital
B. in certain societies lacking equality
C. as people waiting for service at a bank
D. as automobiles waiting for a traffic light
A stack protocol can be used for ( C ).
A. subroutine calls
B. operation of arithmetic expressions
C. removing the latest element inserted
D. removing the earliest element inserted
The operations of a structured data type might act on ( ABCD ).
A. a stack
B. the values of the data type
C. component elements of the data structure
D. a queue
Decide whether the following statements are True or False.
The operations of a structured data type only act on the values of the data type. (×)
A stack is a data type whose major attributes are determined by the rules governing the insertion and deletion of its elements. (√)
A stack is a data type whose data structure is said to have a first-in/last-out (FILO) behavior, or protocol. (√)
The series of jobs awaiting execution is called a queue. (√)
The main feature of queues is that they follow a first-come/first-served rule. (√)
Translate and analyze the following sentences.
A data structure is a data type whose values are composed of component elements that are related by some structure.
句子组成:whose引导定语从句,composed of… 由…组成。
翻译:数据结构是一种数据类型,其值是由通过某种结构相互关联的组成元素所构成的。
In addition, there may be operations that act on its component elements.
句子组成:that引导定语从句,修饰operations。
翻译:并且也可以作用于数据结构的组成元素。
Such a structure is said to have a last-in/first-out (LIFO) behavior.
句子组成:be said to,被动语态。
翻译:这就是所谓具有后进先出(LIFO)性质或协议的结构。
There are many applications of the first-in/