Difference between “enqueue” and “dequeue”

前端 未结 6 1716
盖世英雄少女心
盖世英雄少女心 2021-01-30 13:26

Can somebody please explain the main differences? I don\'t have a clear knowledge about these functions in programming for any language.

6条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-30 13:31

    In my opinion one of the worst chosen word's to describe the process, as it is not related to anything in real-life or similar. In general the word "queue" is very bad as if pronounced, it sounds like the English character "q". See the inefficiency here?

    enqueue: to place something into a queue; to add an element to the tail of a queue;

    dequeue to take something out of a queue; to remove the first available element from the head of a queue

    source: https://www.thefreedictionary.com

提交回复
热议问题