01

The initial state of a stack is empty. Push elements A, B, C, and D onto the stack in sequence. Possible pop sequences are:
A: CADB
B: BDCA
C: CDAB
D: Any order

Answer: B
Explanation: Omitted
02


Which of the following statements about queues is correct?
A) A queue is a non-linear list.
B) A queue organizes data according to the “last in, first out” principle.
C) Data is deleted from the rear of the queue.
D) A queue organizes data according to the “first in, first out” principle.
Answer: D
Explanation: Omitted
03

For circular queues, which of the following statements is correct?
A) The front pointer is fixed and does not change.
B) The front pointer is always greater than the rear pointer.
C) The front pointer is always less than the rear pointer.
D) The front pointer can be greater than or less than the rear pointer.

Answer: D
Explanation: Omitted
04

Assuming a circular queue has a capacity of 50, if the front pointer front=45 (pointing to the position before the front element) and the rear pointer rear=10 (pointing to the rear element), how many elements are in the circular queue?

Answer: 15
Explanation: When rear < front, the number of elements = capacity + rear – front
05

Which of the following statements is correct?
A) A circular queue has both front and rear pointers, therefore, it is a non-linear structure.
B) In a circular queue, only the front pointer is needed to reflect the dynamic changes of the elements in the queue.
C) In a circular queue, only the rear pointer is needed to reflect the dynamic changes of the elements in the queue.
D) The number of elements in a circular queue is determined by both the front and rear pointers.

Answer: D
Explanation: Omitted
06

Which of the following statements is correct?
A) The storage space required for the linked storage structure of a linear list is the same as that for the sequential storage structure.
B) The storage space required for the linked storage structure of a linear list is generally more than that for the sequential storage structure.
C) The storage space required for the linked storage structure of a linear list is generally less than that for the sequential storage structure.
D) None of the above statements are correct.

Answer: B
Explanation: Omitted
07


Which of the following statements about linear linked lists is correct?
A) The storage space of each data node can be non-contiguous, but their storage order must be consistent with the logical order.
B) The storage order of each data node can be inconsistent with the logical order, but their storage space must be contiguous.
C) Insertion and deletion do not require moving elements in the list.
D) None of the above statements are correct.
Answer: C
Explanation: Omitted
08

Which of the following statements about linear linked lists is correct?
A) Storage space does not have to be contiguous, and the storage order of each element is arbitrary.
B) Storage space does not have to be contiguous, and earlier elements must be stored before later elements.
C) Storage space must be contiguous, and earlier elements must be stored before later elements.
D) Storage space must be contiguous, and the storage order of each element is arbitrary.

Answer: A
Explanation: Omitted
09



Answer: A
Explanation: The C language specifies that function definitions must include a pair of curly braces {}, even if the function body is empty; omitting the braces will result in a syntax error.

10



Answer: ADEF
Explanation: Omitted
11 (Common Mistake)



Answer: BCD
Explanation: For option D: In standard C, the number and type of actual parameters must strictly match the formal parameters during function calls, otherwise, a compilation error will occur. If the actual parameter type does not match the formal parameter but can be implicitly converted, the compiler may issue a warning but still allow it.
12



Answer: E
Explanation: The order of passing parameters is not specified by the standard, and the order of calculation is not specified by the standard; it cannot be asserted to be in a fixed direction.
13



Answer: ACD
Explanation: Omitted
14



Answer: BC
Explanation: Omitted
15



Answer: AD
Explanation: For option B: The type of the function’s return value is not determined by the type of the expression after the return statement, but by the function’s type.
For option C: The function type does not require strict consistency with the return expression type.
16 (Common Mistake)



Answer: ACD
Explanation: For option B: Users can redefine standard library functions, but this will override the library function, losing its original functionality and potentially causing issues.
For option C: The system allows users to redefine standard library functions.
For option D: Calling standard library functions does not require redefinition; you only need to include the header file to call them directly.
17



Answer: A
Explanation: Omitted
18




Answer: C
Explanation: Omitted
19



Answer: A
Explanation: Omitted
20



Answer: BCD
Explanation: Omitted
21



Answer: A or D
Explanation: If the function’s type is not void, it returns an uncertain value, select A; if the function’s type is void, it does not return a value, select D.
22



Answer: ACD
Explanation: Omitted
23




Answer: ABC
Explanation: Omitted
24



Answer: C
Explanation: Omitted
25



Answer: ABD
Explanation: Omitted
26



Answer: B
Explanation: Omitted
27



Answer: AD
Explanation: Omitted
28





Answer: C
Explanation: Omitted