File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 755
755
might define).
756
756
757
757
\pnum
758
+ \begin {note }
758
759
The sequence containers
759
760
offer the programmer different complexity trade-offs and should be used
760
761
accordingly.
761
- \tcode {vector} or \tcode {array}
762
+ \tcode {vector}
762
763
is the type of sequence container that should be used by default.
764
+ \tcode {array}
765
+ should be used when the container has a fixed size known during translation.
763
766
\tcode {list} or \tcode {forward_list}
764
767
should be used when there are frequent insertions and deletions from the
765
768
middle of the sequence.
766
769
\tcode {deque}
767
770
is the data structure of choice
768
771
when most insertions and deletions take place at the beginning or at the
769
772
end of the sequence.
773
+ When choosing a container, remember \tcode {vector} is best;
774
+ leave a comment to explain if you choose from the rest!
775
+ \end {note }
770
776
771
777
\pnum
772
778
In Tables~\ref {tab:containers.sequence.requirements }
You can’t perform that action at this time.
0 commit comments