* [Caml-list] Time complexity of Queue.length
@ 2020-02-25 19:05 Yann Salmon
0 siblings, 0 replies; only message in thread
From: Yann Salmon @ 2020-02-25 19:05 UTC (permalink / raw)
To: caml-list
Greetings,
the OCaml standard library documents Stack.length to be O(1).
This is not guaranteed by the documentation of Queue.length, although
the current implementation is just reading the relevant field in the
structure and is therefore O(1).
I wonder what is the reason for this apparent discrepancy. Is it to
allow for a radical change of Queue implementation in the future ?
--
Cordialement,
Yann Salmon
Professeur agrégé
Informatique en CPGE
Lycée Descartes - Tours
<https://pro.yannsalmon.fr/>
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-02-25 19:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-25 19:05 [Caml-list] Time complexity of Queue.length Yann Salmon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox