[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

queue-length should be O(1) ?

This page is part of the web mail archives of SRFI 117 from before July 7th, 2015. The new archives for SRFI 117 contain all messages, not just those from before July 7th, 2015.



Hi.

Seems to be a useful draft, thanks.

One remark about queue-length:
as queues are much more restricted than lists, it would
be easy to store (and update) the queue-length in the underlying
representation of the queue.
This would change O(n) (for queue-length) into O(1).
If you imagine large queues, O(n) could make this SRFI unattractive
or impractical.

Ciao
Sven