C + + double Ended Queues (bidirectional queue)

Source: Internet
Author: User

a bidirectional queue is similar to a vector, but it allows for quick insertion and deletion of the container's head (as in the tail).
Constructors Create a new bidirectional queue
Operators Comparing and assigning bidirectional queues
Assign () Set the value of a two-way queue
at () Returns the specified element
Back () Returns the last element
Begin () Returns an iterator that points to the first element
Clear () Delete all elements
Empty () Returns true if the two-way queue is empty
End () Returns an iterator pointing to the tail
Erase () Delete an element
Front () Returns the first element
Get_allocator () Returns the Configurator for two-way queues
Insert () Inserting an element into a bidirectional queue
Max_size () Returns the maximum number of elements that a two-way queue can hold
Pop_back () Delete the trailing element
Pop_front () Delete the element of the head
Push_back () Add an element to the tail
Push_front () Add an element to the head
Rbegin () Returns a reverse iterator pointing to the tail
Rend () Returns a reverse iterator pointing to the head
Resize () Change the size of the two-way queue
Size () Returns the number of elements in a two-way queue
Swap () And another bidirectional queue interchange element

C + + double Ended Queues (bidirectional queue)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.