Efficient queue in Haskell

前端 未结 4 751
攒了一身酷
攒了一身酷 2021-02-01 04:58

How can I efficiently implement a list data structure where I can have 2 views to the head and end of the list, that always point to a head a tail of a list without expensive ca

4条回答
  •  终归单人心
    2021-02-01 05:16

    Is Data.Dequeue what you are looking for?

    (It doesn't have reverse but you can add it pretty easily and send a patch to the author.)

提交回复
热议问题