CompTIA ITF+ (FC0-U61) — Question 233

A programmer needs an element that will automatically store customer orders consecutively by order number every time a new order is placed. Which of the following elements should be used?

Answer options

Correct answer: B

Explanation

The correct answer is B, Sequence, as it allows for the automatic storage and arrangement of items in a specific order, which is ideal for tracking customer orders. A Vector and an Array are both fixed in size or require manual resizing, while a Constant does not store multiple values, making them unsuitable for this scenario.